radix_engine_interface/api/
blueprint_api.rs

1use radix_common::prelude::VersionedScryptoSchema;
2use radix_common::types::*;
3use sbor::rust::prelude::*;
4use sbor::rust::vec::Vec;
5
6pub trait SystemBlueprintApi<E> {
7    /// Calls a function on a blueprint
8    fn call_function(
9        &mut self,
10        package_address: PackageAddress,
11        blueprint_name: &str,
12        function_name: &str,
13        args: Vec<u8>,
14    ) -> Result<Vec<u8>, E>;
15
16    /// Retrieves the schema of type under a blueprint
17    fn resolve_blueprint_type(
18        &mut self,
19        blueprint_type_id: &BlueprintTypeIdentifier,
20    ) -> Result<(Rc<VersionedScryptoSchema>, ScopedTypeId), E>;
21}