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

@gnosis.pm/safe-react-gateway-sdk

Package Overview
Dependencies
Maintainers
4
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gnosis.pm/safe-react-gateway-sdk - npm Package Compare versions

Comparing version 2.5.8 to 2.6.0

dist/types/safe-apps.d.ts

6

dist/index.d.ts

@@ -5,2 +5,4 @@ import { operations } from './types/api';

import { ChainListResponse, ChainInfo } from './types/chains';
import { SafeAppsResponse } from './types/safe-apps';
export * from './types/safe-apps';
export * from './types/transactions';

@@ -57,1 +59,5 @@ export * from './types/chains';

export declare function getChainConfig(baseUrl: string, chainId: string): Promise<ChainInfo>;
/**
* Returns Safe Apps List
*/
export declare function getSafeApps(baseUrl: string, chainId: string): Promise<SafeAppsResponse>;

2

dist/index.min.js

@@ -1,2 +0,2 @@

!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports['"@gnosis.pm/safe-react-gateway-sdk"']=n():e['"@gnosis.pm/safe-react-gateway-sdk"']=n()}(self,(function(){return(()=>{var e={204:(e,n,t)=>{e.exports=self.fetch||(self.fetch=t(869).default||t(869))},869:(e,n,t)=>{"use strict";function r(e,n){return n=n||{},new Promise((function(t,r){var a=new XMLHttpRequest,s=[],o=[],i={},u=function(){return{ok:2==(a.status/100|0),statusText:a.statusText,status:a.status,url:a.responseURL,text:function(){return Promise.resolve(a.responseText)},json:function(){return Promise.resolve(a.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([a.response]))},clone:u,headers:{keys:function(){return s},entries:function(){return o},get:function(e){return i[e.toLowerCase()]},has:function(e){return e.toLowerCase()in i}}}};for(var c in a.open(n.method||"get",e,!0),a.onload=function(){a.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,(function(e,n,t){s.push(n=n.toLowerCase()),o.push([n,t]),i[n]=i[n]?i[n]+","+t:t})),t(u())},a.onerror=r,a.withCredentials="include"==n.credentials,n.headers)a.setRequestHeader(c,n.headers[c]);a.send(n.body||null)}))}t.r(n),t.d(n,{default:()=>r})}},n={};function t(r){var a=n[r];if(void 0!==a)return a.exports;var s=n[r]={exports:{}};return e[r](s,s.exports,t),s.exports}t.n=e=>{var n=e&&e.__esModule?()=>e.default:()=>e;return t.d(n,{a:n}),n},t.d=(e,n)=>{for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},t.o=(e,n)=>Object.prototype.hasOwnProperty.call(e,n),t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};return(()=>{"use strict";t.r(r),t.d(r,{FEATURES:()=>u,GAS_PRICE_TYPE:()=>i,Operation:()=>e,RPC_AUTHENTICATION:()=>o,TokenType:()=>s,TransactionStatus:()=>n,TransferDirection:()=>a,getBalances:()=>I,getChainConfig:()=>_,getChainsConfig:()=>C,getCollectibles:()=>N,getFiatCurrencies:()=>h,getOwnedSafes:()=>p,getSafeInfo:()=>l,getTransactionDetails:()=>A,getTransactionHistory:()=>E,getTransactionQueue:()=>T,postSafeGasEstimation:()=>O,proposeTransaction:()=>y});var e,n,a,s,o,i,u,c=t(204),f=t.n(c);function d(e,n,t,r){var a,s=r;if(!s){var o=t;s=""+e+function(e,n){return n?Object.keys(n).reduce((function(e,t){return function(e,n,t){return e.replace(new RegExp("\\{"+n+"\\}","g"),t)}(e,t,String(n[t]))}),e):e}(n,null==o?void 0:o.path)+function(e){if(!e)return"";var n=new URLSearchParams;Object.keys(e).forEach((function(t){null!=e[t]&&n.append(t,String(e[t]))}));var t=n.toString();return t?"?"+t:""}(null==o?void 0:o.query),a=null==o?void 0:o.body}return function(e,n){return t=this,r=void 0,s=function(){var t,r,a,s,o;return function(e,n){var t,r,a,s,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return s={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function i(s){return function(i){return function(s){if(t)throw new TypeError("Generator is already executing.");for(;o;)try{if(t=1,r&&(a=2&s[0]?r.return:s[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,s[1])).done)return a;switch(r=0,a&&(s=[2&s[0],a.value]),s[0]){case 0:case 1:a=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!a||s[1]>a[0]&&s[1]<a[3])){o.label=s[1];break}if(6===s[0]&&o.label<a[1]){o.label=a[1],a=s;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(s);break}a[2]&&o.ops.pop(),o.trys.pop();continue}s=n.call(e,o)}catch(e){s=[6,e],r=0}finally{t=a=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,i])}}}(this,(function(i){switch(i.label){case 0:return null!=n&&(t={method:"POST",body:"string"==typeof n?n:JSON.stringify(n),headers:{"Content-Type":"application/json"}}),[4,f()(e,t)];case 1:return[4,(r=i.sent()).json()];case 2:if(a=i.sent(),!r.ok){s="";try{s=(o=a).code+": "+o.message}catch(e){s=r.statusText}throw new Error(s)}return[2,a]}}))},new((a=void 0)||(a=Promise))((function(e,n){function o(e){try{u(s.next(e))}catch(e){n(e)}}function i(e){try{u(s.throw(e))}catch(e){n(e)}}function u(n){var t;n.done?e(n.value):(t=n.value,t instanceof a?t:new a((function(e){e(t)}))).then(o,i)}u((s=s.apply(t,r||[])).next())}));var t,r,a,s}(s,a)}function l(e,n,t){return d(e,"/chains/{chainId}/safes/{address}/",{path:{chainId:n,address:t}})}function I(e,n,t,r,a){return void 0===r&&(r="usd"),void 0===a&&(a={}),d(e,"/chains/{chainId}/safes/{address}/balances/{currency}/",{path:{chainId:n,address:t,currency:r},query:a})}function h(e){return d(e,"/balances/supported-fiat-codes")}function p(e,n,t){return d(e,"/chains/{chainId}/owners/{address}/safes",{path:{chainId:n,address:t}})}function N(e,n,t,r){return void 0===r&&(r={}),d(e,"/chains/{chainId}/safes/{address}/collectibles/",{path:{chainId:n,address:t},query:r})}function E(e,n,t,r){return d(e,"/chains/{chainId}/safes/{safe_address}/transactions/history",{path:{chainId:n,safe_address:t},query:{}},r)}function T(e,n,t,r){return d(e,"/chains/{chainId}/safes/{safe_address}/transactions/queued",{path:{chainId:n,safe_address:t},query:{}},r)}function A(e,n,t){return d(e,"/chains/{chainId}/transactions/{transactionId}",{path:{chainId:n,transactionId:t}})}function O(e,n,t,r){return d(e,"/chains/{chainId}/safes/{safe_address}/multisig-transactions/estimations",{path:{chainId:n,safe_address:t},body:r})}function y(e,n,t,r){return d(e,"/chains/{chainId}/transactions/{safe_address}/propose",{path:{chainId:n,safe_address:t},body:r})}function C(e,n){return d(e,"/chains/",{query:n})}function _(e,n){return d(e,"/chains/{chainId}/",{path:{chainId:n}})}!function(e){e[e.CALL=0]="CALL",e[e.DELEGATE=1]="DELEGATE"}(e||(e={})),function(e){e.AWAITING_CONFIRMATIONS="AWAITING_CONFIRMATIONS",e.AWAITING_EXECUTION="AWAITING_EXECUTION",e.CANCELLED="CANCELLED",e.FAILED="FAILED",e.SUCCESS="SUCCESS",e.PENDING="PENDING",e.PENDING_FAILED="PENDING_FAILED",e.WILL_BE_REPLACED="WILL_BE_REPLACED"}(n||(n={})),function(e){e.INCOMING="INCOMING",e.OUTGOING="OUTGOING",e.UNKNOWN="UNKNOWN"}(a||(a={})),function(e){e.ERC20="ERC20",e.ERC721="ERC721",e.NATIVE_COIN="NATIVE_COIN"}(s||(s={})),function(e){e.API_KEY_PATH="API_KEY_PATH",e.NO_AUTHENTICATION="NO_AUTHENTICATION",e.UNKNOWN="UNKNOWN"}(o||(o={})),function(e){e.ORACLE="ORACLE",e.FIXED="FIXED",e.UNKNOWN="UNKNOWN"}(i||(i={})),function(e){e.ERC721="ERC721",e.ERC1155="ERC1155",e.SAFE_APPS="SAFE_APPS",e.CONTRACT_INTERACTION="CONTRACT_INTERACTION",e.DOMAIN_LOOKUP="DOMAIN_LOOKUP",e.SPENDING_LIMIT="SPENDING_LIMIT",e.EIP1559="EIP1559",e.SAFE_TX_GAS_OPTIONAL="SAFE_TX_GAS_OPTIONAL"}(u||(u={}))})(),r})()}));
!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports['"@gnosis.pm/safe-react-gateway-sdk"']=n():e['"@gnosis.pm/safe-react-gateway-sdk"']=n()}(self,(function(){return(()=>{var e={204:(e,n,t)=>{e.exports=self.fetch||(self.fetch=t(869).default||t(869))},869:(e,n,t)=>{"use strict";function r(e,n){return n=n||{},new Promise((function(t,r){var a=new XMLHttpRequest,s=[],o=[],i={},c=function(){return{ok:2==(a.status/100|0),statusText:a.statusText,status:a.status,url:a.responseURL,text:function(){return Promise.resolve(a.responseText)},json:function(){return Promise.resolve(a.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([a.response]))},clone:c,headers:{keys:function(){return s},entries:function(){return o},get:function(e){return i[e.toLowerCase()]},has:function(e){return e.toLowerCase()in i}}}};for(var u in a.open(n.method||"get",e,!0),a.onload=function(){a.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,(function(e,n,t){s.push(n=n.toLowerCase()),o.push([n,t]),i[n]=i[n]?i[n]+","+t:t})),t(c())},a.onerror=r,a.withCredentials="include"==n.credentials,n.headers)a.setRequestHeader(u,n.headers[u]);a.send(n.body||null)}))}t.r(n),t.d(n,{default:()=>r})}},n={};function t(r){var a=n[r];if(void 0!==a)return a.exports;var s=n[r]={exports:{}};return e[r](s,s.exports,t),s.exports}t.n=e=>{var n=e&&e.__esModule?()=>e.default:()=>e;return t.d(n,{a:n}),n},t.d=(e,n)=>{for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},t.o=(e,n)=>Object.prototype.hasOwnProperty.call(e,n),t.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};return(()=>{"use strict";t.r(r),t.d(r,{FEATURES:()=>c,GAS_PRICE_TYPE:()=>i,Operation:()=>e,RPC_AUTHENTICATION:()=>o,TokenType:()=>s,TransactionStatus:()=>n,TransferDirection:()=>a,getBalances:()=>I,getChainConfig:()=>_,getChainsConfig:()=>C,getCollectibles:()=>N,getFiatCurrencies:()=>h,getOwnedSafes:()=>p,getSafeApps:()=>S,getSafeInfo:()=>l,getTransactionDetails:()=>A,getTransactionHistory:()=>E,getTransactionQueue:()=>T,postSafeGasEstimation:()=>O,proposeTransaction:()=>y});var e,n,a,s,o,i,c,u=t(204),f=t.n(u);function d(e,n,t,r){var a,s=r;if(!s){var o=t;s=""+e+function(e,n){return n?Object.keys(n).reduce((function(e,t){return function(e,n,t){return e.replace(new RegExp("\\{"+n+"\\}","g"),t)}(e,t,String(n[t]))}),e):e}(n,null==o?void 0:o.path)+function(e){if(!e)return"";var n=new URLSearchParams;Object.keys(e).forEach((function(t){null!=e[t]&&n.append(t,String(e[t]))}));var t=n.toString();return t?"?"+t:""}(null==o?void 0:o.query),a=null==o?void 0:o.body}return function(e,n){return t=this,r=void 0,s=function(){var t,r,a,s,o;return function(e,n){var t,r,a,s,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return s={next:i(0),throw:i(1),return:i(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function i(s){return function(i){return function(s){if(t)throw new TypeError("Generator is already executing.");for(;o;)try{if(t=1,r&&(a=2&s[0]?r.return:s[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,s[1])).done)return a;switch(r=0,a&&(s=[2&s[0],a.value]),s[0]){case 0:case 1:a=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((a=(a=o.trys).length>0&&a[a.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!a||s[1]>a[0]&&s[1]<a[3])){o.label=s[1];break}if(6===s[0]&&o.label<a[1]){o.label=a[1],a=s;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(s);break}a[2]&&o.ops.pop(),o.trys.pop();continue}s=n.call(e,o)}catch(e){s=[6,e],r=0}finally{t=a=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,i])}}}(this,(function(i){switch(i.label){case 0:return null!=n&&(t={method:"POST",body:"string"==typeof n?n:JSON.stringify(n),headers:{"Content-Type":"application/json"}}),[4,f()(e,t)];case 1:return[4,(r=i.sent()).json()];case 2:if(a=i.sent(),!r.ok){s="";try{s=(o=a).code+": "+o.message}catch(e){s=r.statusText}throw new Error(s)}return[2,a]}}))},new((a=void 0)||(a=Promise))((function(e,n){function o(e){try{c(s.next(e))}catch(e){n(e)}}function i(e){try{c(s.throw(e))}catch(e){n(e)}}function c(n){var t;n.done?e(n.value):(t=n.value,t instanceof a?t:new a((function(e){e(t)}))).then(o,i)}c((s=s.apply(t,r||[])).next())}));var t,r,a,s}(s,a)}function l(e,n,t){return d(e,"/chains/{chainId}/safes/{address}/",{path:{chainId:n,address:t}})}function I(e,n,t,r,a){return void 0===r&&(r="usd"),void 0===a&&(a={}),d(e,"/chains/{chainId}/safes/{address}/balances/{currency}/",{path:{chainId:n,address:t,currency:r},query:a})}function h(e){return d(e,"/balances/supported-fiat-codes")}function p(e,n,t){return d(e,"/chains/{chainId}/owners/{address}/safes",{path:{chainId:n,address:t}})}function N(e,n,t,r){return void 0===r&&(r={}),d(e,"/chains/{chainId}/safes/{address}/collectibles/",{path:{chainId:n,address:t},query:r})}function E(e,n,t,r){return d(e,"/chains/{chainId}/safes/{safe_address}/transactions/history",{path:{chainId:n,safe_address:t},query:{}},r)}function T(e,n,t,r){return d(e,"/chains/{chainId}/safes/{safe_address}/transactions/queued",{path:{chainId:n,safe_address:t},query:{}},r)}function A(e,n,t){return d(e,"/chains/{chainId}/transactions/{transactionId}",{path:{chainId:n,transactionId:t}})}function O(e,n,t,r){return d(e,"/chains/{chainId}/safes/{safe_address}/multisig-transactions/estimations",{path:{chainId:n,safe_address:t},body:r})}function y(e,n,t,r){return d(e,"/chains/{chainId}/transactions/{safe_address}/propose",{path:{chainId:n,safe_address:t},body:r})}function C(e,n){return d(e,"/chains/",{query:n})}function _(e,n){return d(e,"/chains/{chainId}/",{path:{chainId:n}})}function S(e,n){return d(e,"/chains/{chainId}/safe-apps",{path:{chainId:n}})}!function(e){e[e.CALL=0]="CALL",e[e.DELEGATE=1]="DELEGATE"}(e||(e={})),function(e){e.AWAITING_CONFIRMATIONS="AWAITING_CONFIRMATIONS",e.AWAITING_EXECUTION="AWAITING_EXECUTION",e.CANCELLED="CANCELLED",e.FAILED="FAILED",e.SUCCESS="SUCCESS",e.PENDING="PENDING",e.PENDING_FAILED="PENDING_FAILED",e.WILL_BE_REPLACED="WILL_BE_REPLACED"}(n||(n={})),function(e){e.INCOMING="INCOMING",e.OUTGOING="OUTGOING",e.UNKNOWN="UNKNOWN"}(a||(a={})),function(e){e.ERC20="ERC20",e.ERC721="ERC721",e.NATIVE_COIN="NATIVE_COIN"}(s||(s={})),function(e){e.API_KEY_PATH="API_KEY_PATH",e.NO_AUTHENTICATION="NO_AUTHENTICATION",e.UNKNOWN="UNKNOWN"}(o||(o={})),function(e){e.ORACLE="ORACLE",e.FIXED="FIXED",e.UNKNOWN="UNKNOWN"}(i||(i={})),function(e){e.ERC721="ERC721",e.SAFE_APPS="SAFE_APPS",e.CONTRACT_INTERACTION="CONTRACT_INTERACTION",e.DOMAIN_LOOKUP="DOMAIN_LOOKUP",e.SPENDING_LIMIT="SPENDING_LIMIT",e.EIP1559="EIP1559",e.SAFE_TX_GAS_OPTIONAL="SAFE_TX_GAS_OPTIONAL"}(c||(c={}))})(),r})()}));
//# sourceMappingURL=index.min.js.map
import { FiatCurrencies, OwnedSafes, SafeBalanceResponse, SafeCollectibleResponse, SafeInfo } from './common';
import { MultisigTransactionRequest, TransactionDetails, SafeTransactionEstimation, SafeTransactionEstimationRequest, TransactionListPage } from './transactions';
import { ChainListResponse, ChainInfo } from './chains';
import { SafeAppsResponse } from './safe-apps';
export interface paths {

@@ -113,2 +114,10 @@ '/chains/{chainId}/safes/{address}/': {

};
'/chains/{chainId}/safe-apps': {
get: operations['safe_apps_read'];
parameters: {
path: {
chainId: string;
};
};
};
}

@@ -320,2 +329,15 @@ export interface operations {

};
safe_apps_read: {
parameters: {
path: {
/** A unique value identifying this chain. */
chainId: string;
};
};
responses: {
200: {
schema: SafeAppsResponse;
};
};
};
}

@@ -10,2 +10,3 @@ import { FiatCurrencies, OwnedSafes, SafeBalanceResponse, SafeCollectibleResponse, SafeInfo } from './common'

import { ChainListResponse, ChainInfo } from './chains'
import { SafeAppsResponse } from './safe-apps'

@@ -121,2 +122,10 @@ export interface paths {

}
'/chains/{chainId}/safe-apps': {
get: operations['safe_apps_read']
parameters: {
path: {
chainId: string
}
}
}
}

@@ -329,2 +338,15 @@

}
safe_apps_read: {
parameters: {
path: {
/** A unique value identifying this chain. */
chainId: string
}
}
responses: {
200: {
schema: SafeAppsResponse
}
}
}
}

@@ -46,3 +46,2 @@ export declare enum RPC_AUTHENTICATION {

ERC721 = "ERC721",
ERC1155 = "ERC1155",
SAFE_APPS = "SAFE_APPS",

@@ -49,0 +48,0 @@ CONTRACT_INTERACTION = "CONTRACT_INTERACTION",

@@ -56,3 +56,2 @@ export enum RPC_AUTHENTICATION {

ERC721 = 'ERC721',
ERC1155 = 'ERC1155',
SAFE_APPS = 'SAFE_APPS',

@@ -59,0 +58,0 @@ CONTRACT_INTERACTION = 'CONTRACT_INTERACTION',

{
"name": "@gnosis.pm/safe-react-gateway-sdk",
"version": "2.5.8",
"version": "2.6.0",
"main": "dist/index.min.js",

@@ -5,0 +5,0 @@ "types": "dist/index.d.ts",

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