Comments (8)
I would be interested in working on this.
What scope do you have in mind? JSON-RPC (& REST)? Which API calls? Perhaps we could use the wiki to draft up a quick API spec.
As web framework it would probably makes sense to just use Twisted, since it is already used as networking lib in neo-python. http://twistedmatrix.com/documents/current/web/howto/
from neo-python.
A few notes: I did some research and testing with the Twisted web API. The documentation is not easy to follow, looks outdated in many areas, is not always reproducible, and is in general hard to implement.
Two popular web frameworks for using with Twisted are:
- https://github.com/twisted/klein (ReadTheDocs): popular and semi-active
- https://github.com/iancmcc/txrestapi: inactive since several years
Klein let's users define web routes/APIs like this:
from klein import Klein
app = Klein()
@app.route('/')
def pg_root(request):
return 'I am the root page!'
@app.route('/about')
def pg_about(request):
return 'I am a Klein application!'
app.run("localhost", 8080)
From a developer usability point of view, I think Klein would be a good choice for implementing the JSON-RPC and REST API on top of Twisted.
from neo-python.
Klein looks good! I also like this reference from their read me Klein Bottle
from neo-python.
See also #108 for related code.
from neo-python.
Question: What would be a few interesting API calls to start with?
from neo-python.
- Original RPC server implementation: https://github.com/neo-project/neo/blob/master/neo/Network/RPC/RpcServer.cs
- JSON RPC API reference https://github.com/neo-project/neo/wiki/API-Reference
from neo-python.
Work has started: https://github.com/CityOfZion/neo-python/tree/jsonrpc1
from neo-python.
Closing in favor of #189
from neo-python.
Related Issues (20)
- Circular map reference causes Python stack overflow
- Docker build exits with errors HOT 9
- Parser breaks when reading --tx-attr argument with spaces HOT 3
- Privatenet fails to initialize HOT 2
- neo-python can't sync with Neo 2.10.3 nodes HOT 1
- Deploy Neo Smart Contract at runtiime. HOT 5
- Wallet & np-api-server issues HOT 2
- BigInteger ToByteArray incompatible with neo-vm v3.0.0 HOT 1
- Unclaimed gas calculation incorrect HOT 6
- About NEP-5 Smart Contracts HOT 8
- docker 只有Ubuntu的吗,在centos上运行出错
- centos7下,运行np-prompt,卡顿后后,ctrl + z 退出后,再此运行np-prompt,报错 HOT 1
- 运行np-prompt后,prompt.log中报错, HOT 1
- 运行np-prompt后,没有出现NEO命令行
- Connect to node problem HOT 2
- TestNet bootstrap HOT 1
- prompt input parser parses nested lists incorrectly HOT 1
- Simple Policy Plugin HOT 6
- np-bootstrap -c configure my local sync node that haved sync and the block data is finish. HOT 1
- np-bootstrap hangs at confirm prompt HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from neo-python.