{ "openapi": "3.0.2", "info": { "title": "Gomora dApp API", "description": "A Gomora template for building EVM-compatible API and smart contract indexers and listeners", "termsOfService": "https://github.com/Nuxify/gomora-dapp", "contact": { "name": "Gomora dApp API Developer", "email": "hello@nuxify.tech" }, "version": "v1.10.3" }, "servers": [ { "url": "https://gomora-dapp-api.nuxify.tech/v1", "description": "Production" }, { "url": "https://staging-gomora-dapp-api.nuxify.tech/v1", "description": "Staging" }, { "url": "http://localhost:8000/v1", "description": "Local" } ], "tags": [ { "name": "nft", "description": "NFT service" } ], "paths": { "/nft/greeting/latest": { "get": { "tags": ["nft"], "summary": "Get Greeting", "description": "Gets greeting message", "responses": { "200": { "description": "Success", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/APIResponse" }, { "type": "object", "properties": { "data": { "type": "object", "properties": { "greeting": { "type": "string" } } } } } ] } } } }, "4xx": { "description": "Client side errors", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIErrorResponse" } } } }, "5xx": { "description": "Server side errors", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIErrorResponse" } } } } } } }, "/nft/greeting/logs": { "get": { "tags": ["nft"], "summary": "Get Greeting Contract Event Logs", "description": "Gets greeting contract event logs", "responses": { "200": { "description": "Success", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/APIResponse" }, { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/GetGreeterContractEventLogResponse" } } } } ] } } } }, "4xx": { "description": "Client side errors", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIErrorResponse" } } } }, "5xx": { "description": "Server side errors", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIErrorResponse" } } } } } } }, "/nft/replay": { "get": { "tags": ["nft"], "summary": "Replay Greeter Contract Events", "description": "Replays greeter contract events by block number", "parameters": [ { "name": "fromBlock", "in": "query", "description": "from block number", "required": true, "schema": { "type": "string" } }, { "name": "toBlock", "in": "query", "description": "to block number", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIResponse" } } } }, "4xx": { "description": "Client side errors", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIErrorResponse" } } } }, "5xx": { "description": "Server side errors", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/APIErrorResponse" } } } } } } } }, "components": { "schemas": { "APIResponse": { "type": "object", "properties": { "success": { "type": "boolean", "example": true }, "message": { "type": "string", "example": "Operation successful" }, "data": { "type": "object", "example": {} } } }, "APIErrorResponse": { "type": "object", "properties": { "success": { "type": "boolean", "example": false }, "message": { "type": "string", "example": "Bad Request" }, "errorCode": { "type": "string", "example": "BAD_REQUEST" }, "data": { "type": "object", "example": {} } } }, "GetGreeterContractEventLogResponse": { "type": "object", "properties": { "txHash": { "type": "string" }, "logIndex": { "type": "string" }, "contractAddress": { "type": "string" }, "chain": { "type": "string", "enum": ["ETHEREUM"] }, "event": { "type": "string", "enum": ["LogSetGreeting"] }, "metadata": { "type": "object", "example": {} }, "blockTimestamp": { "type": "integer" } } } } } }