Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@reservoir0x/reservoir-sdk

Package Overview
Dependencies
Maintainers
8
Versions
187
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@reservoir0x/reservoir-sdk - npm Package Compare versions

Comparing version 0.7.1 to 0.7.2

6

CHANGELOG.md

@@ -0,1 +1,7 @@

## [v0.7.1-SDK](https://github.com/reservoirprotocol/reservoir-kit/commit/985268ee145e864fa15781e001505755ed22cdb0) (2023-04-03)
- Fix buyToken method regression, refresh token not triggered when buying a token that fails to be purchased [2023-04-04](https://github.com/reservoirprotocol/reservoir-kit/commit/d15707e)
- Sync api [6f68c95](https://github.com/reservoirprotocol/reservoir-kit/commit/6f68c95135b1b53cb8f07355e7bce8553c98bae5)
## [v0.7.0-SDK](https://github.com/reservoirprotocol/reservoir-kit/commit/1a88adbe5702e73ff1df400537404a3de546919f) (2023-03-23)

@@ -2,0 +8,0 @@

34

dist/index.js

@@ -104,3 +104,3 @@ var $lPQI4$etherslibutils = require("ethers/lib/utils");

var $134f7602d1733f79$exports = {};
$134f7602d1733f79$exports = JSON.parse('{"name":"@reservoir0x/reservoir-sdk","version":"0.7.1","description":"An SDK that can be used in any javascript/typescript context to easily interact with Reservoir liquidity APIs","source":"src/index.ts","main":"dist/index.js","module":"dist/index.module.js","types":"dist/index.d.ts","author":"Reservoir Protocol","license":"MIT","files":["dist"],"scripts":{"clean":"rm -rf dist","version":"yarn version","version:package":"sh ../../scripts/package-version.sh","version:update":"yarn version ${0}; PACKAGE_VERSION=$(yarn version:package); git add -A; git commit -m \\"\uD83C\uDF89 Release client package v$PACKAGE_VERSION\\"; git tag v${PACKAGE_VERSION}-SDK; git push --tags;","syncApi":"node ./sync-api.mjs","changelog":"node ../../scripts/generate-changelog.js package=sdk"},"repository":{"type":"git","url":"https://github.com/reservoirprotocol/reservoir-kit"},"sideEffects":false,"keywords":["nft","reservoir","reservoir-sdk","reservoirkit","protocol","sdk"],"peerDependencies":{"ethers":"^5.6.1"},"dependencies":{"axios":"^0.27.2"},"publishConfig":{"access":"public"},"devDependencies":{"openapi-typescript":"^5.4.1"}}');
$134f7602d1733f79$exports = JSON.parse('{"name":"@reservoir0x/reservoir-sdk","version":"0.7.2","description":"An SDK that can be used in any javascript/typescript context to easily interact with Reservoir liquidity APIs","source":"src/index.ts","main":"dist/index.js","module":"dist/index.module.js","types":"dist/index.d.ts","author":"Reservoir Protocol","license":"MIT","files":["dist"],"scripts":{"clean":"rm -rf dist","version":"yarn version","version:package":"sh ../../scripts/package-version.sh","version:update":"yarn version ${0}; PACKAGE_VERSION=$(yarn version:package); git add -A; git commit -m \\"\uD83C\uDF89 Release client package v$PACKAGE_VERSION\\"; git tag v${PACKAGE_VERSION}-SDK; git push --tags;","syncApi":"node ./sync-api.mjs","changelog":"node ../../scripts/generate-changelog.js package=sdk"},"repository":{"type":"git","url":"https://github.com/reservoirprotocol/reservoir-kit"},"sideEffects":false,"keywords":["nft","reservoir","reservoir-sdk","reservoirkit","protocol","sdk"],"peerDependencies":{"ethers":"^5.6.1"},"dependencies":{"axios":"^0.27.2"},"publishConfig":{"access":"public"},"devDependencies":{"openapi-typescript":"^5.4.1"}}');

@@ -478,2 +478,16 @@

const baseApiUrl = (_a = client.currentChain()) === null || _a === void 0 ? void 0 : _a.baseApiUrl;
const errHandler = ()=>{
items.forEach(({ token: token })=>{
if (token) {
const data = {
token: token
};
(0, $b3114c59012a233a$export$b5fe3f66a567bec0)({
method: "POST",
url: `${baseApiUrl}/tokens/refresh/v1`,
data: JSON.stringify(data)
}).catch(()=>{});
}
});
};
if (!baseApiUrl) throw new ReferenceError("ReservoirClient missing chain configuration");

@@ -492,16 +506,8 @@ try {

data: params
}, signer, onProgress, undefined, expectedPrice);
}, signer, onProgress, undefined, expectedPrice).catch((err)=>{
errHandler();
throw err;
});
} catch (err) {
items.forEach(({ token: token })=>{
if (token) {
const data = {
token: token
};
(0, $b3114c59012a233a$export$b5fe3f66a567bec0)({
method: "POST",
url: `${baseApiUrl}/tokens/refresh/v1`,
data: JSON.stringify(data)
}).catch(()=>{});
}
});
errHandler();
throw err;

@@ -508,0 +514,0 @@ }

@@ -101,3 +101,3 @@ import {arrayify as $9C8uf$arrayify} from "ethers/lib/utils";

var $d3dd819ecb91ce83$exports = {};
$d3dd819ecb91ce83$exports = JSON.parse('{"name":"@reservoir0x/reservoir-sdk","version":"0.7.1","description":"An SDK that can be used in any javascript/typescript context to easily interact with Reservoir liquidity APIs","source":"src/index.ts","main":"dist/index.js","module":"dist/index.module.js","types":"dist/index.d.ts","author":"Reservoir Protocol","license":"MIT","files":["dist"],"scripts":{"clean":"rm -rf dist","version":"yarn version","version:package":"sh ../../scripts/package-version.sh","version:update":"yarn version ${0}; PACKAGE_VERSION=$(yarn version:package); git add -A; git commit -m \\"\uD83C\uDF89 Release client package v$PACKAGE_VERSION\\"; git tag v${PACKAGE_VERSION}-SDK; git push --tags;","syncApi":"node ./sync-api.mjs","changelog":"node ../../scripts/generate-changelog.js package=sdk"},"repository":{"type":"git","url":"https://github.com/reservoirprotocol/reservoir-kit"},"sideEffects":false,"keywords":["nft","reservoir","reservoir-sdk","reservoirkit","protocol","sdk"],"peerDependencies":{"ethers":"^5.6.1"},"dependencies":{"axios":"^0.27.2"},"publishConfig":{"access":"public"},"devDependencies":{"openapi-typescript":"^5.4.1"}}');
$d3dd819ecb91ce83$exports = JSON.parse('{"name":"@reservoir0x/reservoir-sdk","version":"0.7.2","description":"An SDK that can be used in any javascript/typescript context to easily interact with Reservoir liquidity APIs","source":"src/index.ts","main":"dist/index.js","module":"dist/index.module.js","types":"dist/index.d.ts","author":"Reservoir Protocol","license":"MIT","files":["dist"],"scripts":{"clean":"rm -rf dist","version":"yarn version","version:package":"sh ../../scripts/package-version.sh","version:update":"yarn version ${0}; PACKAGE_VERSION=$(yarn version:package); git add -A; git commit -m \\"\uD83C\uDF89 Release client package v$PACKAGE_VERSION\\"; git tag v${PACKAGE_VERSION}-SDK; git push --tags;","syncApi":"node ./sync-api.mjs","changelog":"node ../../scripts/generate-changelog.js package=sdk"},"repository":{"type":"git","url":"https://github.com/reservoirprotocol/reservoir-kit"},"sideEffects":false,"keywords":["nft","reservoir","reservoir-sdk","reservoirkit","protocol","sdk"],"peerDependencies":{"ethers":"^5.6.1"},"dependencies":{"axios":"^0.27.2"},"publishConfig":{"access":"public"},"devDependencies":{"openapi-typescript":"^5.4.1"}}');

@@ -475,2 +475,16 @@

const baseApiUrl = (_a = client.currentChain()) === null || _a === void 0 ? void 0 : _a.baseApiUrl;
const errHandler = ()=>{
items.forEach(({ token: token })=>{
if (token) {
const data = {
token: token
};
(0, $ce40c15ff138f6b7$export$b5fe3f66a567bec0)({
method: "POST",
url: `${baseApiUrl}/tokens/refresh/v1`,
data: JSON.stringify(data)
}).catch(()=>{});
}
});
};
if (!baseApiUrl) throw new ReferenceError("ReservoirClient missing chain configuration");

@@ -489,16 +503,8 @@ try {

data: params
}, signer, onProgress, undefined, expectedPrice);
}, signer, onProgress, undefined, expectedPrice).catch((err)=>{
errHandler();
throw err;
});
} catch (err) {
items.forEach(({ token: token })=>{
if (token) {
const data = {
token: token
};
(0, $ce40c15ff138f6b7$export$b5fe3f66a567bec0)({
method: "POST",
url: `${baseApiUrl}/tokens/refresh/v1`,
data: JSON.stringify(data)
}).catch(()=>{});
}
});
errHandler();
throw err;

@@ -505,0 +511,0 @@ }

{
"name": "@reservoir0x/reservoir-sdk",
"version": "0.7.1",
"version": "0.7.2",
"description": "An SDK that can be used in any javascript/typescript context to easily interact with Reservoir liquidity APIs",

@@ -5,0 +5,0 @@ "source": "src/index.ts",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc