Skip to content

Instantly share code, notes, and snippets.

View anurag-arjun's full-sized avatar

Anurag anurag-arjun

View GitHub Profile
@anurag-arjun
anurag-arjun / deposit.js
Created January 10, 2019 11:37
Depositing Funds from Kovan to Matic
const Matic = require('maticjs').default
const config = require('./config')
const token = '0x670568761764f53E6C10cd63b71024c31551c9EC' // test token address
const amount = '10000000000000000' // amount in wei (0.01 TEST)
const from = '0xdcd53258BA8A69C6a505300BE75447A772bFd3d6' // from address
// Create object of Matic
const matic = new Matic({
maticProvider: config.MATIC_PROVIDER,
parentProvider: config.PARENT_PROVIDER,
[
{
"constant": true,
"inputs": [],
"name": "name",
"outputs": [
{
"name": "",
"type": "string"
}
[
{
"constant": true,
"inputs": [],
"name": "childChainContract",
"outputs": [
{
"name": "",
"type": "address"
}