inspect_fixture.go
TEXT FILE644 B · Public source code for developers, search crawlers and AI agents
1//go:build ignore
2
3package main
4
5import (
6 "encoding/json"
7 "fmt"
8 "os"
9)
10
11func main() {
12 b, e := os.ReadFile("send_fixture.json")
13 if e != nil {
14 panic(e)
15 }
16 var v struct {
17 ReplySource string `json:"reply_source"`
18 Result struct {
19 Result struct {
20 TXID string `json:"txid"`
21 Requested int64 `json:"requested_sat"`
22 Recipient int64 `json:"recipient_sat"`
23 } `json:"result"`
24 } `json:"result"`
25 }
26 if e = json.Unmarshal(b, &v); e != nil {
27 panic(e)
28 }
29 fmt.Printf("reply_source=%s requested=%d recipient=%d txid=%s\n", v.ReplySource, v.Result.Result.Requested, v.Result.Result.Recipient, v.Result.Result.TXID)
30}Read-only source · Select a line number to link directly · Raw download above
