URL: /api/blog/v1.0/blog/{blog}/posts/{post}/comments/{comment}
Method: PUT (POST)
Example request in python:
import requests, json
from sjcl import SJCL
comment_encrypted = SJCL().encrypt(
json.dumps({
"author": "Cryptedblog-Team",
"content": "Just a test comment! Click [here](http://www.cryptedblog.com) to go to the main page. This comment was updated.",
}),
"YourSharedSecret")
response = requests.put(
'http://www.cryptedblog.com/api/blog/v1.0/blog/test-blog/posts/5671831268753408/comments/5737664527466496',
data=json.dumps({
"comment-encrypted": comment_encrypted,
"write-id": "7e5f3ce982194fff914029dbab29fa70",
"password": "BadPassword", # optional comment password
})
)
data = response.json()
print(json.dumps(data, indent=4, sort_keys=True))
The output looks like the following:
{
"data": {
"comment": 5737664527466496,
"comment-url": "/api/blog/v1.0/blog/test-blog/posts/5671831268753408/comments/5737664527466496"
},
"success": true
}