-
Notifications
You must be signed in to change notification settings - Fork 912
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
- Loading branch information
1 parent
618e805
commit f70d8ad
Showing
3 changed files
with
123 additions
and
11 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"type": "object", | ||
"additionalProperties": false, | ||
"required": [ "id", "features", "direction", "address" ], | ||
"properties": { | ||
"id": { | ||
"type": "pubkey", | ||
"description": "the peer we connected to" | ||
}, | ||
"features": { | ||
"type": "hex", | ||
"description": "BOLT 9 features bitmap offered by peer" | ||
}, | ||
"direction": { | ||
"type": "string", | ||
"enum": [ "in", "out" ], | ||
"description": "Whether they initiated connection or we did" | ||
}, | ||
"address": { | ||
"type": "object", | ||
"description": "Address information (mainly useful if **direction** is *out*)", | ||
"additionalProperties": true, | ||
"required": [ "type" ], | ||
"properties": { | ||
"type": { | ||
"type": "string", | ||
"enum": [ "local socket", "ipv4", "ipv6", "torv2", "torv3" ], | ||
"description": "Type of connection (*torv2*/*torv3* only if **direction** is *out*)" | ||
} | ||
}, | ||
"oneOf": [ | ||
{ | ||
"additionalProperties": false, | ||
"required": [ "socket" ], | ||
"properties": { | ||
"type": { | ||
"type": "string", | ||
"enum": [ "local socket" ] | ||
}, | ||
"socket": { | ||
"type": "string", | ||
"description": "socket filename" | ||
} | ||
} | ||
}, | ||
{ | ||
"additionalProperties": false, | ||
"required": [ "address", "port" ], | ||
"properties": { | ||
"type": { | ||
"type": "string", | ||
"enum": [ "ipv4", "ipv6", "torv2", "torv3" ] | ||
}, | ||
"address": { | ||
"type": "string", | ||
"description": "address in expected format for **type**" | ||
}, | ||
"port": { | ||
"type": "u16", | ||
"description": "port number" | ||
} | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} |