lnrpc: send custom message

This commit is contained in:
Joost Jager committed 2021-10-15 17:08:53 +02:00
1 parent 5d7e814ea8
commit ae959b16ae
14 files changed
+4451 -3825

No files matched your search

+56 -29
View File
@@ -851,6 +851,39 @@
]
}
},
"/v1/custommessage": {
"post": {
"summary": "lncli: `sendcustom`\nSendCustomMessage sends a custom peer message.",
"operationId": "Lightning_SendCustomMessage",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/lnrpcSendCustomMessageResponse"
}
},
"default": {
"description": "An unexpected error response.",
"schema": {
"$ref": "#/definitions/rpcStatus"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcSendCustomMessageRequest"
}
}
],
"tags": [
"Lightning"
]
}
},
"/v1/debuglevel": {
"post": {
"summary": "lncli: `debuglevel`\nDebugLevel allows a caller to programmatically set the logging verbosity of\nlnd. The logging can be targeted according to a coarse daemon-wide logging\nlevel, or in a granular fashion to specify the logging for a target\nsub-system.",
@@ -1702,17 +1735,6 @@
}
}
},
"parameters": [
{
"name": "body",
"description": " (streaming inputs)",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/lnrpcRPCMiddlewareResponse"
}
}
],
"tags": [
"Lightning"
]
@@ -5766,24 +5788,6 @@
}
}
},
"lnrpcRPCMiddlewareResponse": {
"type": "object",
"properties": {
"request_id": {
"type": "string",
"format": "uint64",
"description": "The unique ID of the intercepted request that this response refers to. Must\nalways be set when giving feedback to an intercept but is ignored for the\ninitial registration message."
},
"register": {
"$ref": "#/definitions/lnrpcMiddlewareRegistration",
"title": "The registration message identifies the middleware that's being\nregistered in lnd. The registration message must be sent immediately\nafter initiating the RegisterRpcMiddleware stream, otherwise lnd will\ntime out the attempt and terminate the request. NOTE: The middleware\nwill only receive interception messages for requests that contain a\nmacaroon with the custom caveat that the middleware declares it is\nresponsible for handling in the registration message! As a security\nmeasure, _no_ middleware can intercept requests made with _unencumbered_\nmacaroons!"
},
"feedback": {
"$ref": "#/definitions/lnrpcInterceptFeedback",
"description": "The middleware received an interception request and gives feedback to\nit. The request_id indicates what message the feedback refers to."
}
}
},
"lnrpcReadyForPsbtFunding": {
"type": "object",
"properties": {
@@ -6008,6 +6012,29 @@
}
}
},
"lnrpcSendCustomMessageRequest": {
"type": "object",
"properties": {
"peer": {
"type": "string",
"format": "byte",
"title": "Peer to send the message to"
},
"type": {
"type": "integer",
"format": "int64",
"description": "Message type. This value needs to be in the custom range (\u003e= 32768)."
},
"data": {
"type": "string",
"format": "byte",
"description": "Raw message data."
}
}
},
"lnrpcSendCustomMessageResponse": {
"type": "object"
},
"lnrpcSendManyRequest": {
"type": "object",
"properties": {