Skip to content

Commit cb1650e

Browse files
authored
PKI State Proof Incremental Key Loading (#3281)
## Summary Followup to #3261 (contained in diff). Use the new key loading routine from the REST API. ## Test Plan New unit tests.
1 parent 7248b95 commit cb1650e

File tree

13 files changed

+967
-366
lines changed

13 files changed

+967
-366
lines changed

daemon/algod/api/algod.oas2.json

Lines changed: 87 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,7 @@
494494
}
495495
},
496496
"404": {
497-
"description": "Application Not Found",
497+
"description": "Participation Key Not Found",
498498
"schema": {
499499
"$ref": "#/definitions/ErrorResponse"
500500
}
@@ -553,6 +553,12 @@
553553
"$ref": "#/definitions/ErrorResponse"
554554
}
555555
},
556+
"404": {
557+
"description": "Participation Key Not Found",
558+
"schema": {
559+
"$ref": "#/definitions/ErrorResponse"
560+
}
561+
},
556562
"500": {
557563
"description": "Internal Error",
558564
"schema": {
@@ -576,14 +582,14 @@
576582
"tags": [
577583
"private"
578584
],
579-
"description": "Delete a given participation key by id",
585+
"description": "Delete a given participation key by ID",
580586
"produces": [
581587
"application/json"
582588
],
583589
"schemes": [
584590
"http"
585591
],
586-
"summary": "Delete a given participation key by id",
592+
"summary": "Delete a given participation key by ID",
587593
"operationId": "DeleteParticipationKeyByID",
588594
"responses": {
589595
"200": {
@@ -601,6 +607,12 @@
601607
"$ref": "#/definitions/ErrorResponse"
602608
}
603609
},
610+
"404": {
611+
"description": "Participation Key Not Found",
612+
"schema": {
613+
"$ref": "#/definitions/ErrorResponse"
614+
}
615+
},
604616
"500": {
605617
"description": "Internal Error",
606618
"schema": {
@@ -616,14 +628,14 @@
616628
"tags": [
617629
"private"
618630
],
619-
"description": "Given a participation id, return information about that participation key",
631+
"description": "Given a participation ID, return information about that participation key",
620632
"produces": [
621633
"application/json"
622634
],
623635
"schemes": [
624636
"http"
625637
],
626-
"summary": "Get participation key info by id",
638+
"summary": "Get participation key info given a participation ID",
627639
"operationId": "GetParticipationKeyByID",
628640
"responses": {
629641
"200": {
@@ -643,7 +655,69 @@
643655
}
644656
},
645657
"404": {
646-
"description": "Application Not Found",
658+
"description": "Participation Key Not Found",
659+
"schema": {
660+
"$ref": "#/definitions/ErrorResponse"
661+
}
662+
},
663+
"500": {
664+
"description": "Internal Error",
665+
"schema": {
666+
"$ref": "#/definitions/ErrorResponse"
667+
}
668+
},
669+
"default": {
670+
"description": "Unknown Error"
671+
}
672+
}
673+
},
674+
"post": {
675+
"tags": [
676+
"private"
677+
],
678+
"description": "Given a participation ID, append state proof keys to a particular set of participation keys",
679+
"consumes": [
680+
"application/msgpack"
681+
],
682+
"produces": [
683+
"application/json"
684+
],
685+
"parameters": [
686+
{
687+
"description": "The state proof keys to add to an existing participation ID",
688+
"name": "keymap",
689+
"in": "body",
690+
"required": true,
691+
"schema": {
692+
"type": "string",
693+
"format": "binary"
694+
}
695+
}
696+
],
697+
"schemes": [
698+
"http"
699+
],
700+
"summary": "Append state proof keys to a participation key",
701+
"operationId": "AppendKeys",
702+
"responses": {
703+
"200": {
704+
"description": "OK",
705+
"$ref": "#/responses/ParticipationKeyResponse"
706+
},
707+
"400": {
708+
"description": "Bad Request",
709+
"schema": {
710+
"$ref": "#/definitions/ErrorResponse"
711+
}
712+
},
713+
"401": {
714+
"description": "Invalid API Token",
715+
"schema": {
716+
"$ref": "#/definitions/ErrorResponse"
717+
}
718+
},
719+
"404": {
720+
"description": "Participation Key Not Found",
647721
"schema": {
648722
"$ref": "#/definitions/ErrorResponse"
649723
}
@@ -934,7 +1008,7 @@
9341008
},
9351009
"/v2/transactions/pending/{txid}": {
9361010
"get": {
937-
"description": "Given a transaction id of a recently submitted transaction, it returns information about it. There are several cases when this might succeed:\n- transaction committed (committed round \u003e 0)\n- transaction still in the pool (committed round = 0, pool error = \"\")\n- transaction removed from pool due to error (committed round = 0, pool error != \"\")\nOr the transaction may have happened sufficiently long ago that the node no longer remembers it, and this will return an error.\n",
1011+
"description": "Given a transaction ID of a recently submitted transaction, it returns information about it. There are several cases when this might succeed:\n- transaction committed (committed round \u003e 0)\n- transaction still in the pool (committed round = 0, pool error = \"\")\n- transaction removed from pool due to error (committed round = 0, pool error != \"\")\nOr the transaction may have happened sufficiently long ago that the node no longer remembers it, and this will return an error.\n",
9381012
"produces": [
9391013
"application/json",
9401014
"application/msgpack"
@@ -948,7 +1022,7 @@
9481022
{
9491023
"pattern": "[A-Z0-9]+",
9501024
"type": "string",
951-
"description": "A transaction id",
1025+
"description": "A transaction ID",
9521026
"name": "txid",
9531027
"in": "path",
9541028
"required": true
@@ -959,7 +1033,7 @@
9591033
],
9601034
"responses": {
9611035
"200": {
962-
"description": "Given a transaction id of a recently submitted transaction, it returns information about it. There are several cases when this might succeed:\n- transaction committed (committed round \u003e 0)\n- transaction still in the pool (committed round = 0, pool error = \"\")\n- transaction removed from pool due to error (committed round = 0, pool error != \"\")\n\nOr the transaction may have happened sufficiently long ago that the node no longer remembers it, and this will return an error.",
1036+
"description": "Given a transaction ID of a recently submitted transaction, it returns information about it. There are several cases when this might succeed:\n- transaction committed (committed round \u003e 0)\n- transaction still in the pool (committed round = 0, pool error = \"\")\n- transaction removed from pool due to error (committed round = 0, pool error != \"\")\n\nOr the transaction may have happened sufficiently long ago that the node no longer remembers it, and this will return an error.",
9631037
"schema": {
9641038
"$ref": "#/definitions/PendingTransactionResponse"
9651039
}
@@ -998,7 +1072,7 @@
9981072
},
9991073
"/v2/applications/{application-id}": {
10001074
"get": {
1001-
"description": "Given a application id, it returns application information including creator, approval and clear programs, global and local schemas, and global state.",
1075+
"description": "Given a application ID, it returns application information including creator, approval and clear programs, global and local schemas, and global state.",
10021076
"produces": [
10031077
"application/json"
10041078
],
@@ -1061,7 +1135,7 @@
10611135
},
10621136
"/v2/assets/{asset-id}": {
10631137
"get": {
1064-
"description": "Given a asset id, it returns asset information including creator, name, total supply and special addresses.",
1138+
"description": "Given a asset ID, it returns asset information including creator, name, total supply and special addresses.",
10651139
"produces": [
10661140
"application/json"
10671141
],
@@ -2576,7 +2650,7 @@
25762650
}
25772651
},
25782652
"ParticipationKeyResponse": {
2579-
"description": "A detailed description of a participation id",
2653+
"description": "A detailed description of a participation ID",
25802654
"schema": {
25812655
"$ref": "#/definitions/ParticipationKey"
25822656
}
@@ -2593,7 +2667,7 @@
25932667
],
25942668
"properties": {
25952669
"partId": {
2596-
"description": "encoding of the participation id.",
2670+
"description": "encoding of the participation ID.",
25972671
"type": "string"
25982672
}
25992673
}

0 commit comments

Comments
 (0)