{
    "swagger": "2.0",
    "info": {
        "description": "This is an API server for Provers.",
        "title": "Zero-knowledge Prover Stats API",
        "contact": {
            "name": "Prover Stats API Support",
            "email": "Be Pending"
        },
        "license": {
            "name": "Apache 2.0",
            "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
        },
        "version": "1.0"
    },
    "host": "localhost:8990",
    "basePath": "/api/v1",
    "paths": {
        "/api/prover_task/v1/request_token": {
            "get": {
                "description": "login with prover public key",
                "consumes": [
                    "text/plain"
                ],
                "produces": [
                    "text/plain"
                ],
                "tags": [
                    "prover_task"
                ],
                "summary": "login with prover public key",
                "parameters": [
                    {
                        "type": "string",
                        "description": "prover public key",
                        "name": "pubkey",
                        "in": "query",
                        "required": true
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/types.LoginSchema"
                            }
                        }
                    }
                }
            }
        },
        "/api/prover_task/v1/task": {
            "get": {
                "description": "get prover task by task id",
                "consumes": [
                    "text/plain"
                ],
                "produces": [
                    "text/plain"
                ],
                "tags": [
                    "prover_task"
                ],
                "summary": "give the specific prover task",
                "parameters": [
                    {
                        "type": "string",
                        "description": "prover task hash",
                        "name": "task_id",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Bearer license",
                        "name": "Authorization",
                        "in": "header"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/types.ProverTaskSchema"
                        }
                    }
                }
            }
        },
        "/api/prover_task/v1/tasks": {
            "get": {
                "description": "get all the prover task by prover public key",
                "consumes": [
                    "text/plain"
                ],
                "produces": [
                    "text/plain"
                ],
                "tags": [
                    "prover_task"
                ],
                "summary": "get all the prover task by prover public key",
                "parameters": [
                    {
                        "type": "string",
                        "description": "prover public key",
                        "name": "pubkey",
                        "in": "query",
                        "required": true
                    },
                    {
                        "type": "integer",
                        "description": "page",
                        "name": "page",
                        "in": "query",
                        "required": true
                    },
                    {
                        "type": "integer",
                        "description": "page_size",
                        "name": "page_size",
                        "in": "query",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Bearer license",
                        "name": "Authorization",
                        "in": "header"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/types.ProverTaskSchema"
                            }
                        }
                    }
                }
            }
        },
        "/api/prover_task/v1/total_rewards": {
            "get": {
                "description": "get uint64 by prover public key",
                "consumes": [
                    "text/plain"
                ],
                "produces": [
                    "text/plain"
                ],
                "tags": [
                    "prover_task"
                ],
                "summary": "give the total rewards of a prover",
                "parameters": [
                    {
                        "type": "string",
                        "description": "prover public key",
                        "name": "pubkey",
                        "in": "path",
                        "required": true
                    },
                    {
                        "type": "string",
                        "description": "Bearer license",
                        "name": "Authorization",
                        "in": "header"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "schema": {
                            "$ref": "#/definitions/types.ProverTotalRewardsSchema"
                        }
                    }
                }
            }
        }
    },
    "definitions": {
        "types.LoginSchema": {
            "type": "object",
            "properties": {
                "time": {
                    "type": "string"
                },
                "token": {
                    "type": "string"
                }
            }
        },
        "types.ProverTaskSchema": {
            "type": "object",
            "properties": {
                "created_at": {
                    "type": "string"
                },
                "failure_type": {
                    "type": "string"
                },
                "prover_name": {
                    "type": "string"
                },
                "proving_status": {
                    "type": "string"
                },
                "reward": {
                    "type": "string"
                },
                "task_id": {
                    "type": "string"
                },
                "task_type": {
                    "type": "string"
                }
            }
        },
        "types.ProverTotalRewardsSchema": {
            "type": "object",
            "properties": {
                "rewards": {
                    "type": "string"
                }
            }
        }
    },
    "securityDefinitions": {
        "BasicAuth": {
            "type": "basic"
        }
    }
}