Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

curl请求本地全节点钱包方法的时候,无法连接 #39

Open
legeend1 opened this issue Aug 14, 2018 · 6 comments
Open

curl请求本地全节点钱包方法的时候,无法连接 #39

legeend1 opened this issue Aug 14, 2018 · 6 comments

Comments

@legeend1
Copy link

用curl请求正常运行全节点全包方法,本地请求地址为 http://127.0.0.1:9889/,连接不上,提示信息为 Failed to connect to 127.0.0.1 port 9889: Connection refused

@taylorshuang
Copy link
Collaborator

首先要测试telnet localhost 9889,看看端口通了没有,然后,用如下方式访问curl --user user --data-binary '{"method":"方法名","params":["参数"],"id":1}' -H 'content-type: text/plain;' ;' http://127.0.0.1:19889/

@legeend1
Copy link
Author

我是在win下的全节点钱包,只有 telnet localhost 9888 这个端口通,其它的都不通

@taylorshuang
Copy link
Collaborator

端口通,说明服务是开起的,需要看第二步

@legeend1
Copy link
Author

第二步,通过 curl 直接发起 json 请求,请求内容为 {"method":"方法名","params":["参数"],"id":1},地址为 http://127.0.0.1:19889,其它好几个端口都试了,但都连接不上,需要什么注意的么?

@legeend1
Copy link
Author

我用的代码是php发起的json请求,请问有实现此方法的相关代码作参考么,其它语言都可以

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants
@taylorshuang @legeend1 and others