pub fn add_onchain_message<T: Config>(
on_behalf_of: Option<MessageSourceId>,
schema_id: SchemaId,
payload: Vec<u8>,
)Expand description
Add an on-chain message for a given schema id.
§Events
Event::MessagesInBlock- In the next block
§Errors
Error::ExceedsMaxMessagePayloadSizeBytes- Payload is too large.Error::InvalidSchemaId- Schema not found.Error::InvalidPayloadLocation- The schema is not an IPFS payload location.Error::InvalidMessageSourceAccount- Origin must be from an MSA.Error::UnAuthorizedDelegate- Trying to add a message without a proper delegation between the origin and the on_behalf_of MSA.Error::TypeConversionOverflow- Failed to add the message to storage as it is very full.
§Warning: Doc-Only
This function is an automatically generated, and is doc-only, uncallable
stub. See the real version in
Pallet::add_onchain_message.