Duniter4j Elasticsearch offer HTTP access to this sub-API:
Data is made accessible through an HTTP API :
http[s]://node[:port]/... |-- <currency_name>/ | |-- block | |-- blockstat | |-- peer | `-- tx |-- user/ | |-- profile | `-- settings |-- message/ | |-- inbox | `-- outbox `-- invitation/ `-- certification
All stored documents use a JSON format.
Every document have the following mandatory fields:
Document deletion use a document with this mandatory fields:
For instance, a deletion on message/inbox should send this document:
{ "version" : 2, "index" : "message", "type" : "inbox", "id" : "AV9VOeOuTvXJwYisNfU6", "issuer" : "F13aXKWQPGCjSQAxxTyJYyRyPm5SqzFSsYYWSDEQGi2A", "time" : 1509806623, "hash" : "61EBBFBCA630E8B715C360DDE1CD6CABD92B9267CA4B724A2F1F36F0FF7E3455", "signature" : "FOkYCX1b05LTAbtz72F/LMWZb8F8zhQKEqcvbuiQy1N6AXtCUC5Xmjcn+NeO9sCLdcmA0HxsJx42GnWZOmKCDA==" }
A profile document is a JSON document. Mandatory fields are:
Example with only mandatory fields:
{ "version" : 2, "title" : "Pecquot Ludovic", "description" : "Développeur Java et techno client-serveur\nParticipation aux #RML7, #EIS et #Sou", "time" : 1488359903, "issuer" : "2v6tXNxGC1BWaJtUFyPJ1wJ8rbz9v1ZVU1E1LEV2v4ss", "hash" : "F66D43ECD4D38785F424ADB68B3EA13DD56DABDE275BBE780E81E8D4E1D0C5FA", "signature" : "3CWxdLtyY8dky97RZBFLfP6axnfW8KUmhlkiaXC7BN98yg6xE9CkijRBGmuyrx3llPx5HeoGLG99DyvVIKZuCg==" }
Some additional fields are description, socials, tags and avatar :
{ "version" : 2, "title" : "My profile name", "description" : "#developer", "city" : "Rennes", "socials" : [ { "type" : "diaspora", "url" : "https://diaspora-fr.org/people/f9d13420f9ssqzq97aa01beea1f31e2" } ], "time" : 1487422234, "tags" : [ "developer" ], "issuer" : "2ny7YAdmzReQxAayyJZsyVYwYhVyax2thKcGknmQy5nQ", "avatar" : { "_content_type" : "image/png", "_content" : "iVBORw0KGgoAAAANSUhEUgAAAGQAAABkC(...)" // base 64 encoding } "hash" : "85F527077D060E03ECAC6D1AE38A74CCC900ACAF5D52F194BA34F5A5E8A55139", "signature" : "WeP7JEwttAoSkHcuiFwo6N4SM0uVakTYBQ09H1+K8/nPFyxO3ak1U9EQ6qaQFoAx9IdDp5qO2EX662wP/pcEAg==", }