diff --git a/docs/docs.go b/docs/docs.go index 4278f7146..cd322bd2f 100644 --- a/docs/docs.go +++ b/docs/docs.go @@ -34,6 +34,17 @@ const docTemplate = `{ ], "summary": "Try to accept a block proof assignment", "operationId": "create-assignment", + "parameters": [ + { + "description": "assignment request body", + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/prover_server.CreateAssignmentRequestBody" + } + } + ], "responses": { "200": { "description": "OK", @@ -72,6 +83,43 @@ const docTemplate = `{ } }, "definitions": { + "big.Int": { + "type": "object" + }, + "github_com_taikoxyz_taiko-client_bindings_encoding.TierFee": { + "type": "object", + "properties": { + "fee": { + "$ref": "#/definitions/big.Int" + }, + "tier": { + "type": "integer" + } + } + }, + "prover_server.CreateAssignmentRequestBody": { + "type": "object", + "properties": { + "expiry": { + "type": "integer" + }, + "feeToken": { + "type": "string" + }, + "tierFees": { + "type": "array", + "items": { + "$ref": "#/definitions/github_com_taikoxyz_taiko-client_bindings_encoding.TierFee" + } + }, + "txListHash": { + "type": "array", + "items": { + "type": "integer" + } + } + } + }, "prover_server.ProposeBlockResponse": { "type": "object", "properties": { diff --git a/docs/swagger.json b/docs/swagger.json index 762125c07..e0db39db9 100644 --- a/docs/swagger.json +++ b/docs/swagger.json @@ -25,6 +25,17 @@ ], "summary": "Try to accept a block proof assignment", "operationId": "create-assignment", + "parameters": [ + { + "description": "assignment request body", + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/prover_server.CreateAssignmentRequestBody" + } + } + ], "responses": { "200": { "description": "OK", @@ -63,6 +74,43 @@ } }, "definitions": { + "big.Int": { + "type": "object" + }, + "github_com_taikoxyz_taiko-client_bindings_encoding.TierFee": { + "type": "object", + "properties": { + "fee": { + "$ref": "#/definitions/big.Int" + }, + "tier": { + "type": "integer" + } + } + }, + "prover_server.CreateAssignmentRequestBody": { + "type": "object", + "properties": { + "expiry": { + "type": "integer" + }, + "feeToken": { + "type": "string" + }, + "tierFees": { + "type": "array", + "items": { + "$ref": "#/definitions/github_com_taikoxyz_taiko-client_bindings_encoding.TierFee" + } + }, + "txListHash": { + "type": "array", + "items": { + "type": "integer" + } + } + } + }, "prover_server.ProposeBlockResponse": { "type": "object", "properties": { diff --git a/docs/swagger.yaml b/docs/swagger.yaml index 3664a3f93..348f3bf08 100644 --- a/docs/swagger.yaml +++ b/docs/swagger.yaml @@ -1,4 +1,28 @@ definitions: + big.Int: + type: object + github_com_taikoxyz_taiko-client_bindings_encoding.TierFee: + properties: + fee: + $ref: '#/definitions/big.Int' + tier: + type: integer + type: object + prover_server.CreateAssignmentRequestBody: + properties: + expiry: + type: integer + feeToken: + type: string + tierFees: + items: + $ref: '#/definitions/github_com_taikoxyz_taiko-client_bindings_encoding.TierFee' + type: array + txListHash: + items: + type: integer + type: array + type: object prover_server.ProposeBlockResponse: properties: prover: @@ -38,6 +62,13 @@ paths: consumes: - application/json operationId: create-assignment + parameters: + - description: assignment request body + in: body + name: body + required: true + schema: + $ref: '#/definitions/prover_server.CreateAssignmentRequestBody' produces: - application/json responses: diff --git a/prover/server/api.go b/prover/server/api.go index 48243238f..aaacd72fb 100644 --- a/prover/server/api.go +++ b/prover/server/api.go @@ -71,7 +71,7 @@ type ProposeBlockResponse struct { // can submit onchain. // // @Summary Try to accept a block proof assignment -// @ID create-assignment +// @Param body body CreateAssignmentRequestBody true "assignment request body" // @Accept json // @Produce json // @Success 200 {object} ProposeBlockResponse