Skip to content

Commit

Permalink
feat(plugin-validator-besu): generate signature of simple asset
Browse files Browse the repository at this point in the history
Signed-off-by: suyukuoacn <su-yu.kuo@accenture.com>
  • Loading branch information
suyukuoacn authored and petermetz committed Oct 2, 2020
1 parent ff7b21b commit 4c5c253
Show file tree
Hide file tree
Showing 29 changed files with 8,037 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ export enum PluginAspect {
KV_STORAGE = "KV_STORAGE",
WEB_SERVICE = "WEB_SERVICE",
CONSORTIUM = "CONSORTIUM",
VALIDATOR = "VALIDATOR",
}
1 change: 1 addition & 0 deletions packages/cactus-plugin-validator-besu/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
cactus-openapi-spec-plugin-validator-besu.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
{
"openapi": "3.0.3",
"info": {
"title": "Hyperledger Cactus Plugin - Validator Besu Web Service",
"description": "Obtain signatures of ledger state from Cactus nodes through the API .",
"version": "0.0.1"
},
"servers": [
{
"url": "https://www.cactus.stream/{basePath}",
"description": "Public test instance",
"variables": {
"basePath": {
"default": ""
}
}
},
{
"url": "http://localhost:4000/{basePath}",
"description": "Local test instance",
"variables": {
"basePath": {
"default": ""
}
}
}
],
"components": {
"schemas": {
"SignTransactionRequest": {
"type": "object",
"required": [
"transactionHash"
],
"properties": {
"transactionHash": {
"description": "The transaction hash of ledger will be used to fetch the contain.",
"type": "string",
"minLength": 0,
"maxLength": 2048,
"nullable": false
}
}
},
"SignTransactionResponse": {
"type": "object",
"required": [
"signature"
],
"properties": {
"signature": {
"description": "The signatures of ledger from the corresponding transaction hash.",
"type": "string",
"minLength": 0,
"maxLength": 2048,
"nullable": false
}
}
}
}
},
"paths": {
"/api/v1/plugins/@hyperledger/cactus-plugin-validator-besu/sign-transaction": {
"post": {
"summary": "Obtain signatures of ledger from the corresponding transaction hash.",
"description": "Obtain signatures of ledger from the corresponding transaction hash.",
"parameters": [],
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/SignTransactionRequest"
}
}
}
},
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/SignTransactionResponse"
}
}
}
},
"404": {
"description": "Not able to find the corresponding tranaction from the transaction hash"
}
}
}
}
}
}

0 comments on commit 4c5c253

Please sign in to comment.