fuel_core_client/client/schema/
blob.rs1use crate::client::schema::{
2 BlobId,
3 HexString,
4 schema,
5};
6
7#[derive(cynic::QueryVariables, Debug)]
8pub struct BlobByIdArgs {
9 pub id: BlobId,
10}
11
12#[derive(cynic::QueryFragment, Clone, Debug)]
13#[cynic(
14 schema_path = "./assets/schema.sdl",
15 graphql_type = "Query",
16 variables = "BlobByIdArgs"
17)]
18pub struct BlobByIdQuery {
19 #[arguments(id: $id)]
20 pub blob: Option<Blob>,
21}
22
23#[derive(cynic::QueryFragment, Clone, Debug)]
24#[cynic(schema_path = "./assets/schema.sdl")]
25pub struct Blob {
26 pub id: BlobId,
27 pub bytecode: HexString,
28}
29
30#[derive(cynic::QueryFragment, Clone, Debug)]
31#[cynic(schema_path = "./assets/schema.sdl", graphql_type = "Blob")]
32pub struct BlobIdFragment {
33 pub id: BlobId,
34}
35
36#[derive(cynic::QueryFragment, Clone, Debug)]
37#[cynic(
38 schema_path = "./assets/schema.sdl",
39 graphql_type = "Query",
40 variables = "BlobByIdArgs"
41)]
42pub struct BlobExistsQuery {
43 #[arguments(id: $id)]
44 pub blob: Option<BlobIdFragment>,
45}