1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
//! # Fuel Rust SDK.
//!
//! ## Quickstart: `prelude`
//!
//! A prelude is provided which imports all the important data types and traits for you. Use this when you want to quickly bootstrap a new project.
//!
//! ```no_run
//! # #[allow(unused)]
//! use fuels::prelude::*;
//! ```
//!
//! Examples on how you can use the types imported by the prelude can be found in
//! the [test suite](https://github.com/FuelLabs/fuels-rs/tree/master/packages/fuels/tests)

pub mod tx {
    pub use fuel_tx::{
        field, ConsensusParameters, ContractIdExt, ContractParameters, FeeParameters, GasCosts,
        PredicateParameters, Receipt, ScriptExecutionResult, ScriptParameters, StorageSlot,
        Transaction as FuelTransaction, TxId, TxParameters, TxPointer, UpgradePurpose,
        UploadSubsection, UtxoId, Witness,
    };
}

#[cfg(feature = "std")]
pub mod client {
    pub use fuel_core_client::client::{
        pagination::{PageDirection, PaginationRequest},
        FuelClient,
    };
}

pub mod macros {
    pub use fuels_macros::*;
}

#[cfg(feature = "std")]
pub mod programs {
    pub use fuels_programs::*;
}

pub mod core {
    pub use fuels_core::{codec, constants, offsets, traits, Configurables};
}

pub mod crypto {
    pub use fuel_crypto::{Hasher, Message, PublicKey, SecretKey, Signature};
}

pub mod accounts {
    pub use fuels_accounts::*;
}

pub mod types {
    pub use fuels_core::types::*;
}

#[cfg(feature = "std")]
pub mod test_helpers {
    pub use fuels_test_helpers::*;
}

#[doc(hidden)]
pub mod prelude {
    #[cfg(feature = "std")]
    pub use super::{
        accounts::{
            predicate::Predicate,
            provider::*,
            wallet::{generate_mnemonic_phrase, WalletUnlocked},
            Account, ViewOnlyAccount,
        },
        core::{
            codec::{LogDecoder, LogId, LogResult},
            traits::Signer,
        },
        macros::setup_program_test,
        programs::{
            call_utils::TxDependencyExtension,
            contract::{
                CallParameters, Contract, LoadConfiguration, MultiContractCallHandler,
                SettableContract, StorageConfiguration,
            },
        },
        test_helpers::*,
        types::transaction_builders::*,
    };
    pub use super::{
        core::constants::*,
        macros::abigen,
        tx::Receipt,
        types::{
            bech32::{Bech32Address, Bech32ContractId},
            errors::{Error, Result},
            transaction::*,
            Address, AssetId, Bytes, ContractId, RawSlice, Salt,
        },
    };
}