core-lightning/common/bolt11_json.h
Rusty Russell 84dc943cf5 common/bolt11_json: extract bolt11->json code.
Our new "decode" command will also handle bolt11.  We make a few cleanups:

1. Avoid type_to_string() in JSON, instead use format functions directly.
2. Don't need to escape description now that JSON core does that for us.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2021-01-09 14:34:35 +10:30

11 lines
264 B
C

#ifndef LIGHTNING_COMMON_BOLT11_JSON_H
#define LIGHTNING_COMMON_BOLT11_JSON_H
#include "config.h"
struct bolt11;
struct json_stream;
void json_add_bolt11(struct json_stream *response,
const struct bolt11 *b11);
#endif /* LIGHTNING_COMMON_BOLT11_JSON_H */