Skip to content

Commit

Permalink
feat(dataverse): specify RegisterService execute message
Browse files Browse the repository at this point in the history
  • Loading branch information
ccamel committed Oct 24, 2023
1 parent a6b7349 commit 8faf0c1
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion contracts/okp4-dataverse/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,34 @@ pub struct InstantiateMsg {
pub name: String,
}

/// DID is a type alias for a string that represents a Decentralized Identifier (DID).
type DID = String;

/// URI is a type alias for a string that represents a URI.
type URI = String;

/// Execute messages
#[cw_serde]
pub enum ExecuteMsg {}
pub enum ExecuteMsg {
/// # RegisterService
/// RegisterService registers a service in the dataverse.
/// Service is a generic concept for any kind of service that can be provided through a network (e.g. a REST API, a gRPC service, etc.).
///
/// Each service is identified and located by its unique [URI](https://en.wikipedia.org/wiki/Uniform_Resource_Identifier) which defines the entry point
/// of the service.
RegisterService {
/// Identity of the service.
identity: DID,

/// Identifier of the service.
/// This identifier is unique within the scope of the dataverse and is used to reference the service and describe how to interact with it.
identifier: URI,

/// References the individual, company, or organization that is responsible for registering and
/// managing the service.
registrar: URI,
},
}

/// Query messages
#[cw_serde]
Expand Down

0 comments on commit 8faf0c1

Please sign in to comment.