api

Send a POST request to http://upaste.me/api
Required fields:
  • api_key
  • paste
Optional fields:
  • syntax - (default is plain text)
  • name - anything less than 35 character. (default is Unknown)
  • expire - in minutes. 0 -> Never, 60 -> 1 hour. (default is 1 week)
  • privacy - 0 public 1 private. (default is private)
  • json - response in json true or false. (default is false)
Please note that the code below is a decoded json sample.
On success:

{
	"paste":{
		"id":"562eb3",
		"link":"http://upaste.me/562eb3",
		"raw":"http://upaste.me/r/562eb3",
		"download":"http://upaste.me/d/562eb3"
	},
	"status":"success"
}
							
On failure:

{
	"errorcode":1,
	"error":"no_key",
	"status":"error"
}
								
id message
-1 invalid_access
0 invalid_key
1no_content
2invalid_size
3invalid_time
4spam_protect