Skip to content
This repository has been archived by the owner on May 11, 2024. It is now read-only.

Commit

Permalink
Merge branch 'main' into fix/golangci-lint_1
Browse files Browse the repository at this point in the history
  • Loading branch information
mask-pp authored Jan 23, 2024
2 parents 246cfa1 + 9ce7d96 commit ff0a67b
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 28 deletions.
18 changes: 9 additions & 9 deletions docs/docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const docTemplate = `{
"name": "MIT",
"url": "https://github.com/taikoxyz/taiko-client/blob/main/LICENSE.md"
},
"version": "{{.JsonRPC}}"
"version": "{{.Version}}"
},
"host": "{{.Host}}",
"basePath": "{{.BasePath}}",
Expand All @@ -40,15 +40,15 @@ const docTemplate = `{
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/prover_server.CreateAssignmentRequestBody"
"$ref": "#/definitions/server.CreateAssignmentRequestBody"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/prover_server.ProposeBlockResponse"
"$ref": "#/definitions/server.ProposeBlockResponse"
}
},
"422": {
Expand All @@ -74,7 +74,7 @@ const docTemplate = `{
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/prover_server.Status"
"$ref": "#/definitions/server.Status"
}
}
}
Expand All @@ -85,7 +85,7 @@ const docTemplate = `{
"big.Int": {
"type": "object"
},
"github_com_taikoxyz_taiko-client_bindings_encoding.TierFee": {
"encoding.TierFee": {
"type": "object",
"properties": {
"fee": {
Expand All @@ -96,7 +96,7 @@ const docTemplate = `{
}
}
},
"prover_server.CreateAssignmentRequestBody": {
"server.CreateAssignmentRequestBody": {
"type": "object",
"properties": {
"expiry": {
Expand All @@ -108,7 +108,7 @@ const docTemplate = `{
"tierFees": {
"type": "array",
"items": {
"$ref": "#/definitions/github_com_taikoxyz_taiko-client_bindings_encoding.TierFee"
"$ref": "#/definitions/encoding.TierFee"
}
},
"txListHash": {
Expand All @@ -119,7 +119,7 @@ const docTemplate = `{
}
}
},
"prover_server.ProposeBlockResponse": {
"server.ProposeBlockResponse": {
"type": "object",
"properties": {
"maxBlockID": {
Expand All @@ -139,7 +139,7 @@ const docTemplate = `{
}
}
},
"prover_server.Status": {
"server.Status": {
"type": "object",
"properties": {
"maxExpiry": {
Expand Down
16 changes: 8 additions & 8 deletions docs/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/prover_server.CreateAssignmentRequestBody"
"$ref": "#/definitions/server.CreateAssignmentRequestBody"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/prover_server.ProposeBlockResponse"
"$ref": "#/definitions/server.ProposeBlockResponse"
}
},
"422": {
Expand All @@ -65,7 +65,7 @@
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/prover_server.Status"
"$ref": "#/definitions/server.Status"
}
}
}
Expand All @@ -76,7 +76,7 @@
"big.Int": {
"type": "object"
},
"github_com_taikoxyz_taiko-client_bindings_encoding.TierFee": {
"encoding.TierFee": {
"type": "object",
"properties": {
"fee": {
Expand All @@ -87,7 +87,7 @@
}
}
},
"prover_server.CreateAssignmentRequestBody": {
"server.CreateAssignmentRequestBody": {
"type": "object",
"properties": {
"expiry": {
Expand All @@ -99,7 +99,7 @@
"tierFees": {
"type": "array",
"items": {
"$ref": "#/definitions/github_com_taikoxyz_taiko-client_bindings_encoding.TierFee"
"$ref": "#/definitions/encoding.TierFee"
}
},
"txListHash": {
Expand All @@ -110,7 +110,7 @@
}
}
},
"prover_server.ProposeBlockResponse": {
"server.ProposeBlockResponse": {
"type": "object",
"properties": {
"maxBlockID": {
Expand All @@ -130,7 +130,7 @@
}
}
},
"prover_server.Status": {
"server.Status": {
"type": "object",
"properties": {
"maxExpiry": {
Expand Down
16 changes: 8 additions & 8 deletions docs/swagger.yaml
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
definitions:
big.Int:
type: object
github_com_taikoxyz_taiko-client_bindings_encoding.TierFee:
encoding.TierFee:
properties:
fee:
$ref: '#/definitions/big.Int'
tier:
type: integer
type: object
prover_server.CreateAssignmentRequestBody:
server.CreateAssignmentRequestBody:
properties:
expiry:
type: integer
feeToken:
type: string
tierFees:
items:
$ref: '#/definitions/github_com_taikoxyz_taiko-client_bindings_encoding.TierFee'
$ref: '#/definitions/encoding.TierFee'
type: array
txListHash:
items:
type: integer
type: array
type: object
prover_server.ProposeBlockResponse:
server.ProposeBlockResponse:
properties:
maxBlockID:
type: integer
Expand All @@ -36,7 +36,7 @@ definitions:
type: integer
type: array
type: object
prover_server.Status:
server.Status:
properties:
maxExpiry:
type: integer
Expand Down Expand Up @@ -71,14 +71,14 @@ paths:
name: body
required: true
schema:
$ref: '#/definitions/prover_server.CreateAssignmentRequestBody'
$ref: '#/definitions/server.CreateAssignmentRequestBody'
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/prover_server.ProposeBlockResponse'
$ref: '#/definitions/server.ProposeBlockResponse'
"422":
description: prover does not have capacity
schema:
Expand All @@ -95,6 +95,6 @@ paths:
"200":
description: OK
schema:
$ref: '#/definitions/prover_server.Status'
$ref: '#/definitions/server.Status'
summary: Get current prover server status
swagger: "2.0"
3 changes: 1 addition & 2 deletions prover/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"github.com/taikoxyz/taiko-client/pkg/rpc"
)

// @title Taiko Prover API
// @title Taiko Prover Server API
// @version 1.0
// @termsOfService http://swagger.io/terms/

Expand All @@ -29,7 +29,6 @@ import (
// @license.name MIT
// @license.url https://github.com/taikoxyz/taiko-client/blob/main/LICENSE.md

// @host prover-api.test.taiko.xyz
// ProverServer represents a prover server instance.
type ProverServer struct {
echo *echo.Echo
Expand Down
2 changes: 1 addition & 1 deletion scripts/gen_swagger_json.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#/bin/sh

swag init -g prover/server/api.go --parseDependency --parseGoList
swag init -g api.go -d prover/server --pd

0 comments on commit ff0a67b

Please sign in to comment.