Dorothydu's picture
Upload 50 random repository samples
9d3c8f5 verified
{
"source": {
"hash": "0x418399d957539253bbabc230dffce9e131d9d2e7918edd67e9d7d3f6924e3d9e",
"language": "ink! 3.0.0-rc8",
"compiler": "rustc 1.59.0-nightly"
},
"contract": {
"name": "erc20",
"version": "0.1.0",
"authors": [
"[your_name] <[your_email]>"
]
},
"V3": {
"spec": {
"constructors": [
{
"args": [
{
"label": "initial_supply",
"type": {
"displayName": [
"Balance"
],
"type": 0
}
}
],
"docs": [],
"label": "new",
"payable": false,
"selector": "0x9bae9d5e"
}
],
"docs": [],
"events": [
{
"args": [
{
"docs": [],
"indexed": true,
"label": "from",
"type": {
"displayName": [
"Option"
],
"type": 12
}
},
{
"docs": [],
"indexed": true,
"label": "to",
"type": {
"displayName": [
"Option"
],
"type": 12
}
},
{
"docs": [],
"indexed": true,
"label": "value",
"type": {
"displayName": [
"Balance"
],
"type": 0
}
}
],
"docs": [],
"label": "Transfer"
},
{
"args": [
{
"docs": [],
"indexed": true,
"label": "owner",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"docs": [],
"indexed": true,
"label": "spender",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"docs": [],
"indexed": true,
"label": "value",
"type": {
"displayName": [
"Balance"
],
"type": 0
}
}
],
"docs": [],
"label": "Approval"
}
],
"messages": [
{
"args": [],
"docs": [],
"label": "total_supply",
"mutates": false,
"payable": false,
"returnType": {
"displayName": [
"Balance"
],
"type": 0
},
"selector": "0xdb6375a8"
},
{
"args": [
{
"label": "owner",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
}
],
"docs": [],
"label": "balance_of",
"mutates": false,
"payable": false,
"returnType": {
"displayName": [
"Balance"
],
"type": 0
},
"selector": "0x0f755a56"
},
{
"args": [
{
"label": "spender",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"label": "value",
"type": {
"displayName": [
"Balance"
],
"type": 0
}
}
],
"docs": [],
"label": "approve",
"mutates": true,
"payable": false,
"returnType": {
"displayName": [
"bool"
],
"type": 11
},
"selector": "0x681266a0"
},
{
"args": [
{
"label": "owner",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"label": "spender",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
}
],
"docs": [],
"label": "allowance",
"mutates": false,
"payable": false,
"returnType": {
"displayName": [
"Balance"
],
"type": 0
},
"selector": "0x6a00165e"
},
{
"args": [
{
"label": "from",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"label": "to",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"label": "value",
"type": {
"displayName": [
"Balance"
],
"type": 0
}
}
],
"docs": [],
"label": "transfer_from",
"mutates": true,
"payable": false,
"returnType": {
"displayName": [
"bool"
],
"type": 11
},
"selector": "0x0b396f18"
},
{
"args": [
{
"label": "to",
"type": {
"displayName": [
"AccountId"
],
"type": 4
}
},
{
"label": "value",
"type": {
"displayName": [
"Balance"
],
"type": 0
}
}
],
"docs": [],
"label": "transfer",
"mutates": true,
"payable": false,
"returnType": {
"displayName": [
"bool"
],
"type": 11
},
"selector": "0x84a15da1"
}
]
},
"storage": {
"struct": {
"fields": [
{
"layout": {
"cell": {
"key": "0x0000000000000000000000000000000000000000000000000000000000000000",
"ty": 0
}
},
"name": "total_supply"
},
{
"layout": {
"struct": {
"fields": [
{
"layout": {
"struct": {
"fields": [
{
"layout": {
"cell": {
"key": "0x0100000000000000000000000000000000000000000000000000000000000000",
"ty": 1
}
},
"name": "header"
},
{
"layout": {
"struct": {
"fields": [
{
"layout": {
"cell": {
"key": "0x0200000000000000000000000000000000000000000000000000000000000000",
"ty": 2
}
},
"name": "len"
},
{
"layout": {
"array": {
"cellsPerElem": 1,
"layout": {
"cell": {
"key": "0x0200000001000000000000000000000000000000000000000000000000000000",
"ty": 3
}
},
"len": 4294967295,
"offset": "0x0300000000000000000000000000000000000000000000000000000000000000"
}
},
"name": "elems"
}
]
}
},
"name": "entries"
}
]
}
},
"name": "keys"
},
{
"layout": {
"hash": {
"layout": {
"cell": {
"key": "0x0300000001000000000000000000000000000000000000000000000000000000",
"ty": 8
}
},
"offset": "0x0200000001000000000000000000000000000000000000000000000000000000",
"strategy": {
"hasher": "Blake2x256",
"postfix": "",
"prefix": "0x696e6b20686173686d6170"
}
}
},
"name": "values"
}
]
}
},
"name": "balances"
},
{
"layout": {
"struct": {
"fields": [
{
"layout": {
"struct": {
"fields": [
{
"layout": {
"cell": {
"key": "0x0300000001000000000000000000000000000000000000000000000000000000",
"ty": 1
}
},
"name": "header"
},
{
"layout": {
"struct": {
"fields": [
{
"layout": {
"cell": {
"key": "0x0400000001000000000000000000000000000000000000000000000000000000",
"ty": 2
}
},
"name": "len"
},
{
"layout": {
"array": {
"cellsPerElem": 1,
"layout": {
"cell": {
"key": "0x0400000002000000000000000000000000000000000000000000000000000000",
"ty": 9
}
},
"len": 4294967295,
"offset": "0x0500000001000000000000000000000000000000000000000000000000000000"
}
},
"name": "elems"
}
]
}
},
"name": "entries"
}
]
}
},
"name": "keys"
},
{
"layout": {
"hash": {
"layout": {
"cell": {
"key": "0x0500000002000000000000000000000000000000000000000000000000000000",
"ty": 8
}
},
"offset": "0x0400000002000000000000000000000000000000000000000000000000000000",
"strategy": {
"hasher": "Blake2x256",
"postfix": "",
"prefix": "0x696e6b20686173686d6170"
}
}
},
"name": "values"
}
]
}
},
"name": "allowances"
}
]
}
},
"types": [
{
"id": 0,
"type": {
"def": {
"primitive": "u128"
}
}
},
{
"id": 1,
"type": {
"def": {
"composite": {
"fields": [
{
"name": "last_vacant",
"type": 2,
"typeName": "Index"
},
{
"name": "len",
"type": 2,
"typeName": "u32"
},
{
"name": "len_entries",
"type": 2,
"typeName": "u32"
}
]
}
},
"path": [
"ink_storage",
"collections",
"stash",
"Header"
]
}
},
{
"id": 2,
"type": {
"def": {
"primitive": "u32"
}
}
},
{
"id": 3,
"type": {
"def": {
"variant": {
"variants": [
{
"fields": [
{
"type": 7,
"typeName": "VacantEntry"
}
],
"index": 0,
"name": "Vacant"
},
{
"fields": [
{
"type": 4,
"typeName": "T"
}
],
"index": 1,
"name": "Occupied"
}
]
}
},
"params": [
{
"name": "T",
"type": 4
}
],
"path": [
"ink_storage",
"collections",
"stash",
"Entry"
]
}
},
{
"id": 4,
"type": {
"def": {
"composite": {
"fields": [
{
"type": 5,
"typeName": "[u8; 32]"
}
]
}
},
"path": [
"ink_env",
"types",
"AccountId"
]
}
},
{
"id": 5,
"type": {
"def": {
"array": {
"len": 32,
"type": 6
}
}
}
},
{
"id": 6,
"type": {
"def": {
"primitive": "u8"
}
}
},
{
"id": 7,
"type": {
"def": {
"composite": {
"fields": [
{
"name": "next",
"type": 2,
"typeName": "Index"
},
{
"name": "prev",
"type": 2,
"typeName": "Index"
}
]
}
},
"path": [
"ink_storage",
"collections",
"stash",
"VacantEntry"
]
}
},
{
"id": 8,
"type": {
"def": {
"composite": {
"fields": [
{
"name": "value",
"type": 0,
"typeName": "V"
},
{
"name": "key_index",
"type": 2,
"typeName": "KeyIndex"
}
]
}
},
"params": [
{
"name": "V",
"type": 0
}
],
"path": [
"ink_storage",
"collections",
"hashmap",
"ValueEntry"
]
}
},
{
"id": 9,
"type": {
"def": {
"variant": {
"variants": [
{
"fields": [
{
"type": 7,
"typeName": "VacantEntry"
}
],
"index": 0,
"name": "Vacant"
},
{
"fields": [
{
"type": 10,
"typeName": "T"
}
],
"index": 1,
"name": "Occupied"
}
]
}
},
"params": [
{
"name": "T",
"type": 10
}
],
"path": [
"ink_storage",
"collections",
"stash",
"Entry"
]
}
},
{
"id": 10,
"type": {
"def": {
"tuple": [
4,
4
]
}
}
},
{
"id": 11,
"type": {
"def": {
"primitive": "bool"
}
}
},
{
"id": 12,
"type": {
"def": {
"variant": {
"variants": [
{
"index": 0,
"name": "None"
},
{
"fields": [
{
"type": 4
}
],
"index": 1,
"name": "Some"
}
]
}
},
"params": [
{
"name": "T",
"type": 4
}
],
"path": [
"Option"
]
}
}
]
}
}