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

jupiter-node-sdk

Package Overview
Dependencies
Maintainers
2
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jupiter-node-sdk - npm Package Compare versions

Comparing version 0.3.1 to 0.4.0

7

Changelog.md

@@ -6,2 +6,9 @@ # Changelog

## [0.4.0] - 2020-07-25
### Changed
- Increased fee for jupiter-fs binary transactions
### Added
- Added function to get all the transactions with jupiter-fs metadata
## [0.3.1] - 2020-07-15

@@ -8,0 +15,0 @@ ### Changed

1

dist/JupiterClient.d.ts

@@ -42,2 +42,3 @@ /// <reference types="node" />

decryptRecord(message: ITransactionAttachmentDecryptedMessage): Promise<string>;
getAllMatadataTransactions(): Promise<ITransaction[]>;
getAllTransactions(withMessage?: boolean, type?: number, subtype?: number | undefined): Promise<ITransaction[]>;

@@ -44,0 +45,0 @@ getTransaction(txId: string): Promise<ITransaction>;

20

dist/JupiterClient.js

@@ -23,2 +23,4 @@ "use strict";

};
const TYPE_DATA_FS = 8;
const SUBTYPE_MESSAGING_METIS_METADATA_TYPE = 0;
function setClient(serverUrl = opts.server) {

@@ -52,16 +54,19 @@ return axios_1.default.create({

return fee;
if (encryptedMessageLength <= 10000) {
fee = 4000;
if (encryptedMessageLength <= 5000) {
fee = 16500;
}
else if (encryptedMessageLength <= 10000) {
fee = 32000;
}
else if (encryptedMessageLength <= 20000) {
fee = 7000;
fee = 63000;
}
else if (encryptedMessageLength <= 30000) {
fee = 10000;
fee = 94500;
}
else if (encryptedMessageLength <= 40000) {
fee = 13000;
fee = 126000;
}
else {
fee = 16000;
fee = 135000;
}

@@ -209,2 +214,5 @@ return fee;

},
async getAllMatadataTransactions() {
return this.getAllTransactions(true, TYPE_DATA_FS, SUBTYPE_MESSAGING_METIS_METADATA_TYPE);
},
async getAllTransactions(withMessage = true, type = 1, subtype) {

@@ -211,0 +219,0 @@ const [confirmed, unconfirmed] = await Promise.all([

{
"name": "jupiter-node-sdk",
"version": "0.3.1",
"version": "0.4.0",
"description": "A thin wrapper around the Jupiter blockchain APIs.",

@@ -5,0 +5,0 @@ "main": "./dist/index.js",

@@ -20,2 +20,5 @@ import assert from 'assert'

const TYPE_DATA_FS = 8;
const SUBTYPE_MESSAGING_METIS_METADATA_TYPE = 0;
function setClient(serverUrl: string = opts.server) {

@@ -56,12 +59,14 @@ return axios.create({

return fee
if (encryptedMessageLength <= 10000) {
fee = 4000
if (encryptedMessageLength <= 5000) {
fee = 16500
} else if (encryptedMessageLength <= 10000) {
fee = 32000
} else if (encryptedMessageLength <= 20000) {
fee = 7000
fee = 63000
} else if (encryptedMessageLength <= 30000) {
fee = 10000
fee = 94500
} else if (encryptedMessageLength <= 40000) {
fee = 13000
fee = 126000
} else {
fee = 16000
fee = 135000
}

@@ -244,2 +249,7 @@ return fee

async getAllMatadataTransactions(): Promise<ITransaction[]> {
return this.getAllTransactions(true, TYPE_DATA_FS, SUBTYPE_MESSAGING_METIS_METADATA_TYPE)
},
async getAllTransactions(

@@ -246,0 +256,0 @@ withMessage: boolean = true,

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