{"id":18542727,"url":"https://github.com/coinbase/mesh-geth-sdk","last_synced_at":"2026-01-07T23:20:22.791Z","repository":{"id":38204415,"uuid":"481676184","full_name":"coinbase/mesh-geth-sdk","owner":"coinbase","description":"go-ethereum based sdk for Mesh API","archived":false,"fork":false,"pushed_at":"2024-10-24T06:35:03.000Z","size":7613,"stargazers_count":27,"open_issues_count":15,"forks_count":28,"subscribers_count":16,"default_branch":"master","last_synced_at":"2024-10-24T11:57:14.487Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://docs.cdp.coinbase.com/mesh/docs/getting-started/","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/coinbase.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-04-14T16:36:20.000Z","updated_at":"2024-10-21T23:05:14.000Z","dependencies_parsed_at":"2023-02-18T00:31:36.274Z","dependency_job_id":"ce68ba24-b53b-4487-b8c6-d2f87a6821c2","html_url":"https://github.com/coinbase/mesh-geth-sdk","commit_stats":null,"previous_names":["coinbase/mesh-geth-sdk"],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Fmesh-geth-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Fmesh-geth-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Fmesh-geth-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coinbase%2Fmesh-geth-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/coinbase","download_url":"https://codeload.github.com/coinbase/mesh-geth-sdk/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230471175,"owners_count":18231193,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T20:10:04.867Z","updated_at":"2026-01-07T23:20:22.718Z","avatar_url":"https://github.com/coinbase.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch3 align=\"center\"\u003e\nMesh Generic go-ethereum-based SDK\n\u003c/h3\u003e\n\u003c!-- add shields here after publication --\u003e\n\u003cp align=\"center\"\u003e\nBuild once. \nIntegrate your blockchain everywhere.\n\u003c/p\u003e\n\n## Overview\n\nThe `mesh-geth-sdk` repository provides a collection of packages used for interaction with the Mesh API specification. The goal of this SDK is to help accelerate Mesh API implementation on go-ethereum based chains. \n\n[Mesh](https://docs.cdp.coinbase.com/mesh/docs/welcome/) is an open-source specification and set of tools that makes integrating with blockchains simpler, faster, and more reliable. The Mesh API is specified in the [OpenAPI 3.0 format](https://www.openapis.org).\n\nJump to:\n\n* [Getting Started](#Getting-Started)\n* [Quick Examples](#Quick-Examples)\n* [Testing](#Testing)\n* [Documentation](#Documentation)\n* [Related Projects](#Related-Projects)\n\n## Quick Examples\n\n### Complete SDK Example\n\nThis [ethereum example](examples/ethereum/) provides a reference implementation of the Mesh API for Ethereum in Golang. This example highlights how to load a configuration, load supported operation types and errors, create a new Ethereum client, and start the Mesh server.\n\n```go\npackage main\n\nimport (\n\t\"log\"\n\n\t\"github.com/coinbase/mesh-geth-sdk/examples/ethereum/client\"\n\t\"github.com/coinbase/mesh-geth-sdk/examples/ethereum/config\"\n\tsdkTypes \"github.com/coinbase/mesh-geth-sdk/types\"\n\t\"github.com/coinbase/mesh-geth-sdk/utils\"\n)\n\nfunc main() {\n\t// Load configuration using the ENVs in the environment.\n\tcfg, err := config.LoadConfiguration()\n\tif err != nil {\n\t\tlog.Fatalln(\"unable to load configuration: %w\", err)\n\t}\n\n\t// Load all the supported operation types, status\n\ttypes := sdkTypes.LoadTypes()\n\terrors := sdkTypes.Errors\n\n\t// Create a new ethereum client by leveraging SDK functionalities\n\tclient, err := client.NewEthereumClient()\n\tif err != nil {\n\t\tlog.Fatalln(\"cannot initialize client: %w\", err)\n\t}\n\n\t// Bootstrap to start the Mesh API server\n\terr = utils.BootStrap(cfg, types, errors, client)\n\tif err != nil {\n\t\tlog.Fatalln(\"unable to bootstrap Mesh server: %w\", err)\n\t}\n}\n```\n\nThe [LoadConfiguration](examples/ethereum/config/config.go) file loads all the Blockchain metadata and Mesh configuration.\n\nThe [NewEthereumClient](examples/ethereum/client/client.go) file creates a new service client, which leverages SDK functionalities, and implements a few gas related interfaces.\n\n### Valid Tokens\n\nSee (examples/tokenList.json) for a list of supported ERC20 tokens.\n\n### SDK Packages\n\n* [Client](client): Low-level communication with any `go-ethereum` based blockchain\n* [Services](services): Mesh RESTful services for Data and Construction APIs\n* [Utils](utils): Bootstrap code for starting up a Mesh API server\n* [Examples](examples): Examples of how to build your Mesh integration with the SDK\n\n### Configuring the SDK\n\nSee the [Configuration](configuration/configuration.go) file for more information on how to configure the SDK.\n\n### SDK interfaces and method overriding\nThe SDK defines a list of [Client interfaces](services/construction/types.go), which allows the Mesh service to interact with a go-ethereum based blockchain.\n\nThe SDK provides a default implementation of the client module for a quick start. However, these interfaces require custom integration to override:\n\u003c!-- These links will need to be updated when we publish to GitHub --\u003e\n1. [`GetBlockReceipts`](https://github.com/coinbase/mesh-geth-sdk/blob/1a8ac6c199732ab06a40725ccc07f34b52a2b46e/services/construction/types.go#L124)\n2. [`GetTransactionReceipt`](https://github.com/coinbase/mesh-geth-sdk/blob/1a8ac6c199732ab06a40725ccc07f34b52a2b46e/services/construction/types.go#L133)\n3. [`GetNativeTransferGasLimit`](https://github.com/coinbase/mesh-geth-sdk/blob/1a8ac6c199732ab06a40725ccc07f34b52a2b46e/services/construction/types.go#L140)\n\n\n## Development\n\nHelpful commands for development:\n\n### Install dependencies\n\n```\nmake deps\n```\n\n### Run tests\n\n```\nmake test\n```\n\n### Lint the source code\n\n```\nmake lint\n```\n\n### Check for security concerns\n\n```\nmake salus\n```\n\n### Generate a coverage report\n\n```\nmake coverage-local\n```\n\n## Testing\n\nTo validate `mesh-geth-sdk`, [install `mesh-cli`](https://github.com/coinbase/mesh-cli#install) and run one of the following commands:\n\n* `mesh-cli check:data --configuration-file mesh-cli-conf/testnet/config.json` - This command validates that the Data API implementation is correct, using the ethereum `testnet` node. It also ensures that the implementation does not miss any balance-changing operations.\n* `mesh-cli check:construction --configuration-file mesh-cli-conf/testnet/config.json` - This command validates the Construction API implementation. It also verifies transaction construction, signing, and submissions to the `testnet` network.\n* `mesh-cli check:data --configuration-file mesh-cli-conf/mainnet/config.json` - This command validates that the Data API implementation is correct, using the ethereum `mainnet` node. It also ensures that the implementation does not miss any balance-changing operations.\n\nRead the [How to Test your Mesh Implementation](https://docs.cdp.coinbase.com/mesh/docs/mesh-test/) documentation for additional details.\n\n## Contributing\n\nYou may contribute to the `mesh-geth-sdk` project in various ways:\n\n* [Asking Questions](CONTRIBUTING.md/#asking-questions)\n* [Providing Feedback](CONTRIBUTING.md/#providing-feedback)\n* [Reporting Issues](CONTRIBUTING.md/#reporting-issues)\n\nRead our [Contributing](CONTRIBUTING.MD) documentation for more information.\n\nYou can also find community implementations for a variety of blockchains in the [mesh-ecosystem](https://github.com/coinbase/mesh-ecosystem) repository.\n\n## Documentation\n\nYou can find the Mesh API documentation [here](https://docs.cdp.coinbase.com/mesh/docs/welcome/). \n\nCheck out the [Getting Started](https://docs.cdp.coinbase.com/mesh/docs/getting-started/) section to start diving into Mesh. \n\n## Related Projects\n\n* [mesh-sdk-go](https://github.com/coinbase/mesh-sdk-go) — The `mesh-sdk-go` SDK provides a collection of packages used for interaction with the Mesh API specification. \n* [mesh-specifications](https://github.com/coinbase/mesh-specifications) — Much of the SDK code is generated from this repository.\n* [mesh-cli](https://github.com/coinbase/mesh-cli) — Use the `mesh-cli` tool to test your Mesh API implementation. The tool also provides the ability to look up block contents and account balances.\n\n## License\n\nThis project is available open source under the terms of the [Apache 2.0 License](https://opensource.org/licenses/Apache-2.0).\n\n© 2022 Coinbase\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoinbase%2Fmesh-geth-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcoinbase%2Fmesh-geth-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoinbase%2Fmesh-geth-sdk/lists"}