Security News
Input Validation Vulnerabilities Dominate MITRE's 2024 CWE Top 25 List
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Please note that this is still an early version. Breaking changes will most likely occur. Use it at your own risk.
import { SplinterlandsClient } from 'lib-sl';
const main = async () => {
/**
* Create new Client
* Metadata for custom_json broadcasting could be set here: { json: { prefix: 'sm_' <== default, app: 'myslapp' } }
*/
const slClient = new SplinterlandsClient();
/**
* Login with hive-account + private key (could be also email + password)
* This saves the access-token within the client & re-uses when needed
*/
await slClient.login('myaccount', 'privatekey');
const result = await slClient.players.getPlayer('myaccount');
console.log('Player', result);
/**
* Create custom_json operations to be broadcasted to claim staking rewards + ranked/license rewards
*/
const ops = [slClient.players.claimStaking('myaccount', 'SPS'), slClient.players.claimRewards('myaccount')];
/**
* Broadcast to the chain via dhive-sl
*/
await slClient.broadcast(ops, 'myprivatepostingkey');
};
main();
The goal for this library is to provide a better and less error-prone way to interact with the Splinterlands API by returning the raw API data with typings. On top of that, the api data is then being converted to classes and improved upon, i.e. by adding relevant classes (card-details for cards or battles), converting string-arrays to real arrays, etc.
This library should also provide a better way to interact with & broadcast to Hive - i.e. to transfer-tokens, vote on proposals, etc.
FAQs
sl library
We found that lib-sl demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.