From 76aad9d9c3208abb3e7825f4d3fce902e465f7ed Mon Sep 17 00:00:00 2001 From: Richard van der Hoff Date: Fri, 16 Sep 2016 14:05:48 +0100 Subject: Update comment on olm_account_one_time_keys Document what it actually returns. --- include/olm/olm.h | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/olm/olm.h b/include/olm/olm.h index 81b6602..3257e53 100644 --- a/include/olm/olm.h +++ b/include/olm/olm.h @@ -205,7 +205,21 @@ size_t olm_account_one_time_keys_length( ); /** Writes the public parts of the unpublished one time keys for the account - * into the one_time_keys output buffer. Returns olm_error() on failure. + * into the one_time_keys output buffer. + *

+ * The returned data is a JSON-formatted object with the single property + * curve25519, which is itself an object mapping key id to + * base64-encoded Curve25519 key. For example: + *

+ * {
+ *     curve25519: {
+ *         "AAAAAA": "wo76WcYtb0Vk/pBOdmduiGJ0wIEjW4IBMbbQn7aSnTo",
+ *         "AAAAAB": "LRvjo46L1X2vx69sS9QNFD29HWulxrmW11Up5AfAjgU"
+ *     }
+ * }
+ * 
+ * Returns olm_error() on failure. + *

* If the one_time_keys buffer was too small then olm_account_last_error() * will be "OUTPUT_BUFFER_TOO_SMALL". */ size_t olm_account_one_time_keys( -- cgit v1.2.3