Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/oberton/chrome_freeton_extension_js_sdk
SDK to integrate with Oberton Freeton Wallet Chrome Extension https://chrome.google.com/webstore/detail/oberton-chrome-freeton-ex/emdkjliaadghhnaanlbpdgmddbjlmhpi
https://github.com/oberton/chrome_freeton_extension_js_sdk
chrome-extension crystal freeton freeton-sdk ton
Last synced: about 1 month ago
JSON representation
SDK to integrate with Oberton Freeton Wallet Chrome Extension https://chrome.google.com/webstore/detail/oberton-chrome-freeton-ex/emdkjliaadghhnaanlbpdgmddbjlmhpi
- Host: GitHub
- URL: https://github.com/oberton/chrome_freeton_extension_js_sdk
- Owner: oberton
- Created: 2021-08-26T08:21:48.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-09-09T13:23:24.000Z (over 3 years ago)
- Last Synced: 2024-03-24T08:43:06.260Z (10 months ago)
- Topics: chrome-extension, crystal, freeton, freeton-sdk, ton
- Language: JavaScript
- Homepage:
- Size: 112 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# chrome_freeton_extension_js_sdk
more info [sdk.oberton.io](https://sdk.oberton.io)
You can use CDN script
``
or run
`npm install @oberton/sdk`
```
import Oberton from '@oberton/sdk';const oberton = new Oberton();
// EVENTS
oberton
/* extension is not installed or unreacheable
* or transaction failed to sent */
.on('error', (data) => console.log('error', data))/* transaction has been sent */
.on('transactionSent', (data) => console.log('transactionSent', data)) // transactionSent, provides details from the @tonclient SDK/* transaction failed */
.on('transactionFailed', (data) => console.log('transactionFailed', data))/* any response from an extension, included errors and transactions events */
.on('response', (data) => console.log('response', data));// SEND TOKENS
oberton.sendTokens({
to: '0:4b0cc91b506e5cff29eb1cb64f0b543e0d15ac6e3a3743ec462a711abbc7aa36',
amount: 0.5,
payloadType: 'comment',
comment: 'Hello World2',
});
```