User Tools

Site Tools


http-micropayments

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

http-micropayments [2015/10/24 10:24]
donpdonp
http-micropayments [2016/06/25 11:25]
Line 1: Line 1:
-## Cryptocoin HTTP Micropayments 
  
-HTTP Header 
-``` 
-X-micropayment:​ [protocol] 
-``` 
- 
-(from https://​gist.github.com/​sipa/​1237788) 
-  * "​script"​ : base64-encoded txout script that must be present in the created transaction. 
-  * "​amount"​ : bitcoin amount to be sent (optional, in which case the client asks the user). 
- 
-  * GET / 
-    * 200 or 402: receives txout in headers. computes signed tx. 
-  * POST /  
-    * content-type:​ application/​micropayment;​ sends signed TX 
-    * content-type:​ application/​json;​ sends {tx: '​tx',​ refund: '​addr',​ etc.} 
- 
-Fastest: client signs TX, hands to server (no bitcoin network involved). Server can selectively run various checks, including submitting to the bitcoin network and waiting, or trusting valid signature and recent balance. 
http-micropayments.txt ยท Last modified: 2016/06/25 11:25 (external edit)