1
0
mirror of https://github.com/oceanprotocol-archive/squid-js.git synced 2024-02-02 15:31:51 +01:00
Commit Graph

324 Commits

Author SHA1 Message Date
adac2a0dbc
bump lint packages 2019-08-19 13:21:19 +02:00
ccf0b39cf0
bump packages 2019-07-31 13:02:04 +02:00
Pedro Gutiérrez
a9ba23d2c3 Resolve the DDO using the service endpoint on registration event. 2019-07-16 14:56:56 +02:00
Pedro Gutiérrez
cdbc4c93a1 Fix linter errors. 2019-07-15 11:36:06 +02:00
Pedro Gutiérrez
88b8eb06c6 Allow using Secret Store to decrypt the files that are going to be downloaded. 2019-07-15 11:36:06 +02:00
Pedro Gutiérrez
ccbd0daead Restore decryption feature on Secret Store submodule. 2019-07-15 11:36:06 +02:00
Pedro Gutiérrez
a629a04dd4 Move download file behavior to utils. 2019-07-15 11:36:06 +02:00
Pedro Gutiérrez
d3f15e361a Detect the error when a condition is not correctly fulfilled. 2019-07-09 11:39:22 +02:00
Pedro Gutiérrez
031720ad5d Return the correct data format on agreement prepare. 2019-07-03 13:08:00 +02:00
Pedro Gutiérrez
4c3f134942 Fix error on getting contract address of not loaded contracts. 2019-06-25 13:10:08 +02:00
Pedro Gutiérrez
be95da79df Allow Disenser as optional contract. 2019-06-25 11:12:32 +02:00
Pedro Gutiérrez
a80b4aee18 Fix linter issues manually. 2019-06-24 13:06:46 +02:00
b61822e30c format all the things 2019-06-24 13:06:46 +02:00
Pedro Gutiérrez
ba9dc0930d Improve how is get the version data of the squid. 2019-06-18 12:29:51 +02:00
Pedro Gutiérrez
0ca5dae306 Improve version output. 2019-06-14 16:33:05 +02:00
Pedro Gutiérrez
21fa3495c5 Transform the versions object to an array with properties. 2019-06-14 12:05:59 +02:00
Pedro Gutiérrez
0438beef2b Create Versions module. 2019-06-14 00:34:53 +02:00
Pedro Gutiérrez
95d668666b Add authenticate method to account. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
b32f708385 Improve token validation. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
3abe15a023 Send the token when is available to authenticate on Brizo. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
1f83e333cb Improve how can be get the token from the account. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
9dc4b348ce Make Auth modules constants configurable. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
abd4ccac1e Add a error message if localStorage is not available. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
4d73eb8697 Add integration test for Auth module. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
b60e46a0b5 Add the token to the accounts that have it stored. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
b236cda7dd Add Auth module. 2019-05-31 20:41:24 +02:00
Pedro Gutiérrez
7d94cf2b6c Report the asset creation progress. 2019-05-31 18:02:39 +02:00
Pedro Gutiérrez
6fe8430b08 Change the type of the price of an asset to string. 2019-05-30 00:56:16 +02:00
Pedro Gutiérrez
90fbc0b1d6 Expose the granted agreementIds for a consumer. 2019-05-29 12:18:04 +02:00
Pedro Gutiérrez
d363e3cd2a Detect signature errors produced user rejection. #226 2019-05-17 15:29:10 +02:00
Pedro Gutiérrez
d779adc0a3 Move WebServiceConnector to utils and make it instantiable. 2019-05-09 12:53:28 +02:00
Pedro Gutiérrez
99ddff97bc Update order flow using Brizo. 2019-04-30 19:35:34 +02:00
Pedro Gutiérrez
bb1a02a5d1 Fix differences between implementation on DDO generation. 2019-04-30 11:38:11 +02:00
Pedro Gutiérrez
c8411e29d2 Add more events on order execution. 2019-04-25 20:20:24 +02:00
Pedro Gutiérrez
e76c152bfc Fix linter errors. 2019-04-25 20:20:24 +02:00
Pedro Gutiérrez
5b5ad23d7a Emit the progress of ordering a asset. #202 2019-04-25 20:20:24 +02:00
Pedro Gutiérrez
4438206914 Send the DID registry transaction before send the DDO to Aquarius. #200 2019-04-23 12:46:52 +02:00
Pedro Gutiérrez
8f8766d700 Generate the download asset folder name in the same way than squid-py. 2019-04-23 12:46:52 +02:00
Pedro Gutiérrez
b36e3a4f06 Add consumerAssets method to assets module. 2019-04-17 13:54:33 +02:00
Pedro Gutiérrez
47ced8af1b Add ownerAssets method to assets module. 2019-04-17 13:54:33 +02:00
Pedro Gutiérrez
652d4e7575 Add owner method on assets module. 2019-04-17 13:54:33 +02:00
ae4fe65b0e
fix page number in all search queries 2019-04-16 19:01:11 +02:00
Pedro Gutiérrez
b6af27a523 Use only the agreementId on status method of agreements module. 2019-04-16 14:33:42 +02:00
Pedro Gutiérrez
398ec203c1 Add status method to agreements module. 2019-04-16 14:01:30 +02:00
Pedro Gutiérrez
1e94e27f81 Fix wrong prepare output. 2019-04-15 23:17:51 +02:00
Pedro Gutiérrez
29ea28cf90 Fix bug on order assets that was stopping the flow after paying. 2019-04-15 13:33:25 +02:00
Pedro Gutiérrez
b8fec2d084 Use the new Aquarius response type. 2019-04-05 16:11:04 +02:00
Pedro Gutiérrez
3dbc1b90d7 Be able to download a specific file of an asset. 2019-04-04 10:08:03 +02:00
Pedro Gutiérrez
b5727bb8dc Fix lint errors. 2019-04-01 17:41:43 +02:00
Pedro Gutiérrez
c632307646 Upgrade to Keeper 0.9.0 and Secret Store access way. 2019-04-01 17:41:43 +02:00
Pedro Gutiérrez
c5e78899f0 Upgrade to Keeper 0.8.7 2019-04-01 17:41:43 +02:00
Pedro Gutiérrez
a931fe5a42 Move helpers/utils that needs web3 or ocean instance to instantiable classes. 2019-04-01 10:33:38 +02:00
Jernej Pregelj
b38df5d5ed fix search query 2019-03-29 11:58:29 +01:00
Pedro Gutiérrez
7a9cdf6966 Add metadata fields on files. 2019-03-29 11:35:24 +01:00
Pedro Gutiérrez
05ca0da57f Fix linter errors. 2019-03-25 15:21:23 +01:00
Pedro Gutiérrez
7a13ad8daa Be able to create different Ocean instances with different config. 2019-03-25 15:21:23 +01:00
Pedro Gutiérrez
ea16729d86 Replace the main Logger for a instantiable class. 2019-03-25 15:21:23 +01:00
Pedro Gutiérrez
5402d421c8 Remove default exports of Ocean modules. 2019-03-25 15:21:23 +01:00
Pedro Gutiérrez
780475b35f Remove OceanBase. 2019-03-25 15:21:23 +01:00
Pedro Gutiérrez
f3599a5d7f Remove --no-acl-contractflag. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
b821d6c6e0 Remove not needed awaits. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
eaac2f4f68 Fix linter errors. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
01465dc164 Fix Reward condition pointing. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
c976d52378 Upgrade asset.create, asset.order and agreement related methods to work with Keeper 0.8.x. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
4f469b2ab5 Use condition contracts hash generation to generate the signature. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
6a4df9768a Move signature values generation to template. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
c213a8d3ca Create Signature integration test and fixed/improved the generation of hashes. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
ae070be011 Use the decimals of OceanToken to return the correct balance. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
51aa0fbf64 Clean and simplify template related typings. 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
86906b393f added OceanAgreementsConditions submodule 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
c9b383223b fixed some typing issues 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
5ec624b2a5 initial implementation of templates and conditions 2019-03-18 13:37:49 +01:00
Pedro Gutiérrez
5c96be1b0c ignored non stable tests 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
0410793286 linter fixes 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
6d5be0db75 fixed consume flow 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
181940a62c allow having different config in integration test 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
e61e7b8881 improved Logger allowing different log level 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
fce88aa528 added SecretStore integration test 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
dd5c90eb9f added OceanTokens initialization on Ocean 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
fce3a09285 added Ocean.tokens module 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
057714988a added some missed methods on Ocean.accounts module 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
8dcdf0a851 moved ID generator 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
3fd8f995f6 added Ocean.secretStore module 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
42b7c0cced fixed asset.order method behavior 2019-02-26 00:18:07 +01:00
Pedro Gutiérrez
a6d2ce8fde using a SecretStore with custom config 2019-02-20 16:06:04 +01:00
Pedro Gutiérrez
407aba7450 improved Service typing 2019-02-20 16:06:04 +01:00
Pedro Gutiérrez
0a0786a835 be able to use a SecretStore URL defined on the DDO ocean#247 2019-02-20 16:06:04 +01:00
Pedro Gutiérrez
f5ab0e6d05 improved way that is exported Service type 2019-02-20 16:06:04 +01:00
Pedro Gutiérrez
3e50ded2e5 allowing to add new services in the DDO when an asset is created 2019-02-20 16:06:04 +01:00
Pedro Gutiérrez
8fb465fc5b improved Service definition 2019-02-20 16:06:04 +01:00
Pedro Gutiérrez
879921ec0a linter fixes 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
cfda1e6130 added all necessary methods of Ocean.agreements 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
2d4cd891b3 changed returning data of asset.create 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
14f3955ed0 added Search asset tests 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
8bce68a3a5 added test of registration of service agreement templates 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
e1b9197746 added buy asset test 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
e46ef174a2 initial integration test scaffolding 2019-02-14 12:05:31 +01:00
Pedro Gutiérrez
34745f3b66 small changes 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
c56989a710 using files intead of contentUrls on examples ocean#251 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
e88a40dac0 replaces contentUrls by files on DDO ocean#251 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
1336773272 moved checksum length control 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
d51e3f3dbf updated registerAttribute method 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
f82b99792f linter fixes 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
749e77cf53 fixed on imports 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
c24aea4bda adding proof and checksum on asset creation flow 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
518a784554 improved exportation of typings related to DDOs 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
5694ae29b5 changed some methods 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
26e6c534a0 fixed part of the unit test 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
0599ba67fa updated setupTemplate method 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
fc46592fe9 replaced OceanMarket with Dispenser 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
64921829f9 changed name of ServiceExecutionAgreement 2019-02-08 17:37:21 +01:00
Pedro Gutiérrez
95a98daa38 moved main methods to modules by scope 2019-01-25 21:23:37 +01:00
Pedro Gutiérrez
68d551dc09 improves some error messages 2019-01-25 10:53:53 +01:00
Pedro Gutiérrez
86b406ad2e fixed linter issues 2019-01-24 10:58:05 +01:00
Pedro Gutiérrez
c1c3168c64 improved error detection on integration test #118 2019-01-24 10:48:48 +01:00
Pedro Gutiérrez
83cf56b57e fixed error related to asset consuming #114 2019-01-24 10:48:48 +01:00
Pedro Gutiérrez
f71e7e345a linter fixes 2019-01-22 14:18:58 +01:00
Pedro Gutiérrez
5e4a33f4e2 added better DID verification 2019-01-22 14:14:49 +01:00
Pedro Gutiérrez
21b38402ca changed some methods names and marking as deprectated #65 2019-01-15 11:34:45 +01:00
Pedro Gutiérrez
89dbc10532 added comments to main Ocean class #79 2019-01-09 16:39:18 +01:00
Sebastian Gerske
724a29ee80 add detection for meta mask 2018-12-18 15:50:37 +01:00
Jernej Pregelj
e953180700 lint fixes 2018-12-17 17:43:45 +01:00
Jernej Pregelj
81a282af28 return file urls 2018-12-17 16:46:19 +01:00
Sebastian Gerske
6ea480fd47 enhanced did handling 2018-12-17 15:54:58 +01:00
Sebastian Gerske
a0648b4b84 remove 0x prefix from serviceAgreementId 2018-12-17 14:29:09 +01:00
Sebastian Gerske
09191fab59 rollback did containing 0x 2018-12-17 14:17:35 +01:00
Sebastian Gerske
d6495036d7
Merge branch 'develop' into fix/file_download 2018-12-14 16:15:36 +01:00
Sebastian Gerske
77a410c607 removed file-saver and added a callback with the content 2018-12-14 16:12:23 +01:00
Sebastian Gerske
85496f7002 added the check for the status of the template that is used to sign the service agreement 2018-12-14 16:11:26 +01:00
ssallam
233aede5f6 Generate assetId with 0x prefix, update all references to reflect this. This makes it similar to squid-py and fixes an issue in payAsset where the asset id in the condition param had double 0x prefix when paying a service agreement for an asset created in squid-py. 2018-12-14 13:40:08 +01:00
Sebastian Gerske
b2cebf7748 added verbose flag to config 2018-12-11 17:41:10 +01:00
Sebastian Gerske
ce009dcd94 remove fs because it does not work in the browser 2018-12-10 13:26:33 +01:00
ssallam
4f05e3f455 fix saving downloaded file. 2018-12-10 00:15:40 +01:00
ssallam
1756903005 Handle the access granted event. Invoke the consume endpoint. Fix issue in the generated serviceEndpoint. 2018-12-08 00:46:18 +01:00
Sebastian Gerske
d221b14931 fix pay asset 2018-12-07 17:20:20 +01:00
Sebastian Gerske
2310c7103e increase timeout 2018-12-07 16:55:32 +01:00
Sebastian Gerske
0f262f5f03 map events properly 2018-12-07 16:00:33 +01:00
Sebastian Gerske
2c85460285 fix timeout 2018-12-07 15:30:54 +01:00
Sebastian Gerske
382207b904 fix registering 2018-12-07 15:23:17 +01:00
Sebastian Gerske
ce7027590e new access template 2018-12-07 15:19:16 +01:00
Sebastian Gerske
d4b6366a4a latest adoption 2018-12-05 12:40:38 +01:00
ssallam
04c8a7feda Fix aquarius url and the keeper registered url type. 2018-12-04 21:21:13 +01:00
Sebastian Gerske
0981289745 changed formatting 2018-11-27 12:27:15 +01:00
Sebastian Gerske
43a5e53d57 fix brizo connection 2018-11-26 15:24:59 +01:00
Sebastian Gerske
3bf09e63a1 added executeAgreement event listener 2018-11-23 16:09:31 +01:00
Sebastian Gerske
a904649c33 add event listener for lockPayment 2018-11-23 16:01:42 +01:00
Sebastian Gerske
07455e84a9
Merge branch 'develop' into feature/trilobite_countdown 2018-11-23 15:53:34 +01:00
Sebastian Gerske
17f1b3e53e fix listen once 2018-11-23 14:28:41 +01:00
Sebastian Gerske
0c3c21b4c5 fix listener, add eventing, moved generation of conditions to template structure 2018-11-23 14:14:35 +01:00
diminator
faf974d03b Merge remote-tracking branch 'remotes/origin/develop' into deploy/es-cjs-umd-min-builds 2018-11-23 12:57:07 +01:00