{"id":24054640,"url":"https://github.com/cardinal-cryptography/dev-runtime-interfaces","last_synced_at":"2025-07-30T02:08:24.068Z","repository":{"id":229848465,"uuid":"777796447","full_name":"Cardinal-Cryptography/dev-runtime-interfaces","owner":"Cardinal-Cryptography","description":"A collection of useful, dirty runtime interfaces","archived":false,"fork":false,"pushed_at":"2024-04-04T08:02:58.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-01-09T03:49:00.418Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cardinal-Cryptography.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2024-03-26T14:17:19.000Z","updated_at":"2024-03-26T14:48:04.000Z","dependencies_parsed_at":"2024-03-26T16:06:26.300Z","dependency_job_id":null,"html_url":"https://github.com/Cardinal-Cryptography/dev-runtime-interfaces","commit_stats":null,"previous_names":["cardinal-cryptography/dev-runtime-interfaces"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fdev-runtime-interfaces","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fdev-runtime-interfaces/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fdev-runtime-interfaces/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fdev-runtime-interfaces/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cardinal-Cryptography","download_url":"https://codeload.github.com/Cardinal-Cryptography/dev-runtime-interfaces/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240840048,"owners_count":19866164,"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":"2025-01-09T03:49:12.627Z","updated_at":"2025-02-26T10:44:30.634Z","avatar_url":"https://github.com/Cardinal-Cryptography.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# aleph-dev-runtime-interfaces\nA collection of runtime interfaces (Substrate's concept for outsourcing computation from Runtime to the host) for Aleph Zero chain.\n_For development / debugging purposes only._\n\n# Usage\n\n1. Clone the repository:\n```bash\ngit clone https://github.com/Cardinal-Cryptography/dev-runtime-interfaces\n```\n\n2. Change the source of Substrate libraries in [`Cargo.toml`](./Cargo.toml), e.g.:\n```toml\nsp-runtime-interface = { git = \"https://github.com/Cardinal-Cryptography/polkadot-sdk.git\", branch = \"my-experimental-branch\", default-features = false }\n```\n\n3. Add the runtime interfaces to your **node** (enabling the interfaces you need with features) in the node's `Cargo.toml`, e.g.:\n```toml\naleph-dev-runtime-interfaces = { path = \"local/path/to/the/clone\", features = [\"std\", \"now\"] }\n```\n\n4. Register host functions in the node's executor:\n```rust\nimpl sc_executor::NativeExecutionDispatch for ExecutorDispatch {\n    type ExtendHostFunctions = (aleph_dev_runtime_interfaces::now::HostFunctions,);\n    \n    // ...\n}\n```\n\n5. Add the runtime interfaces to your **runtime** (enabling the features you need with features) in the target pallets' `Cargo.toml`, e.g.:\n```toml\naleph-dev-runtime-interfaces = { path = \"local/path/to/the/clone\", default-features = false, features = [\"now\"] }\n```\n\n6. Use the runtime interfaces in your runtime:\n```rust\n#[pallet::weight(...)]\npub fn call(...) -\u003e ... {\n    log::error!(\"[call][start] {}\", aleph_runtime_interfaces::now::now());\n    // ...\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcardinal-cryptography%2Fdev-runtime-interfaces","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcardinal-cryptography%2Fdev-runtime-interfaces","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcardinal-cryptography%2Fdev-runtime-interfaces/lists"}