Skip to content

Instantly share code, notes, and snippets.

@fredspencer
Created August 21, 2018 08:06
Show Gist options
  • Save fredspencer/62c568b8adb18745372935cb8557ad29 to your computer and use it in GitHub Desktop.
Save fredspencer/62c568b8adb18745372935cb8557ad29 to your computer and use it in GitHub Desktop.
--- trim ---
https://peepeth.com/about
https://www.kickstarter.com/projects/1414168019/peepeth-social-network-for-a-better-world
Peepeth's data is open to anyone. The contract is stateless, except for recording unique usernames, so you have to query each block and parse the input data of each transaction according to the following ABI.
For more about stateless contracts, check out this great post.
https://medium.com/@childsmaidment/stateless-smart-contracts-21830b0cd1b6
The ABI and address are all you really need to read and write from Peepeth, but actually implementing a front-end is pretty labor intensive as there are many moving parts. Peepeth.org will make it easier for others to start their own front-ends (by providing code examples).
The user @james (https://peepeth.com/accounts/james) has created a simple Peepeth reader / verifier here: Peepeth reader
https://ipfs.io/ipfs/QmQwNcHfjEXndwagt8ECp3hEXcfCtBJwmNoiKkNXyhs9pG/
(You must be connected to the Main Ethereum network to view).
Peepeth main contract address
0xfa28ec7198028438514b49a3cf353bca5541ce1d
...and ABI
---trim---
[
{
"constant": false,
"inputs": [
{
"name": "_followee",
"type": "address"
}
],
"name": "unFollow",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "updateAccount",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "isActive",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_isActive",
"type": "bool"
}
],
"name": "setIsActive",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_followee",
"type": "address"
}
],
"name": "follow",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_name",
"type": "bytes16"
}
],
"name": "changeName",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "address"
}
],
"name": "names",
"outputs": [
{
"name": "",
"type": "bytes32"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "reply",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "bytes32"
}
],
"name": "addresses",
"outputs": [
{
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_address",
"type": "address"
}
],
"name": "setNewAddress",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "_addr",
"type": "address"
}
],
"name": "accountExists",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "bStr",
"type": "bytes16"
}
],
"name": "isValidName",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "pure",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "share",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "saveBatch",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [],
"name": "cashout",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "owner",
"outputs": [
{
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "post",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_name",
"type": "bytes16"
},
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "createAccount",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "newMinPercentage",
"type": "uint256"
}
],
"name": "setMinSiteTipPercentage",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_author",
"type": "address"
},
{
"name": "_messageID",
"type": "string"
},
{
"name": "_ownerTip",
"type": "uint256"
},
{
"name": "_ipfsHash",
"type": "string"
}
],
"name": "tip",
"outputs": [],
"payable": true,
"stateMutability": "payable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "newAddress",
"outputs": [
{
"name": "",
"type": "address"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [
{
"name": "",
"type": "uint256"
}
],
"name": "interfaceInstances",
"outputs": [
{
"name": "interfaceAddress",
"type": "address"
},
{
"name": "startBlock",
"type": "uint96"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "_address",
"type": "address"
}
],
"name": "transferAccount",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": false,
"inputs": [],
"name": "lockMinSiteTipPercentage",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "interfaceInstanceCount",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "minSiteTipPercentage",
"outputs": [
{
"name": "",
"type": "uint256"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"constant": false,
"inputs": [
{
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "function"
},
{
"constant": true,
"inputs": [],
"name": "tipPercentageLocked",
"outputs": [
{
"name": "",
"type": "bool"
}
],
"payable": false,
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"payable": false,
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"payable": true,
"stateMutability": "payable",
"type": "fallback"
},
{
"anonymous": false,
"inputs": [],
"name": "PeepethEvent",
"type": "event"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment