mirror of
https://github.com/onsonr/sonr.git
synced 2025-03-10 21:09:11 +00:00
* **refactor: remove nebula static file serving** * **feat: Add login, register, and authorize sections** * **feat: implement registration form UI** * **refactor: abstract template rendering to ctx module** * **feat: add deployment target for Highway gateway** * **feat: migrate Highway gateway to Cloudflare Workers** * **feat: refactor nebula routes to components** * **chore(deps): remove unused dependencies** * **chore(deps): remove unused dependencies** * **feat: add user and relaying party entities** * **refactor: remove unused imports** * * **feat: add motion scale-in and opacity-in animations** * **refactor: move dwn and orm packages to internal** * **refactor: update imports to use relative paths** * **refactor: rename build targets for clarity** * **feat: add RelayingPartyEntity model** * **refactor: rename creds templates to credentials** * **refactor: remove unused entity model** * **refactor: move models to internal package** * **refactor: move models package to internal/orm** * **feat: implement broadcast channel context** * **feat: remove config upload step** * **feat: remove unused configuration files** * **feat: migrate authentication logic to workers** * **feat: remove cloudflared dependency** * **refactor: move client related routes to 'routes/client.go'** * **feat: implement macaroon middleware** * **refactor: move fetch package to cmd/motr** * **feat: remove auth and grant endpoints** * **docs: add conceptual descriptions to did module** <sub><a href="https://huly.app/guest/sonrhq?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJsaW5rSWQiOiI2NzA4MTIyNmM3ZDZhNTZhOGY4ZGFjOTciLCJndWVzdCI6InRydWUiLCJlbWFpbCI6IiNndWVzdEBoYy5lbmdpbmVlcmluZyIsIndvcmtzcGFjZSI6InctcHJhZC1zb25yaHEtNjVlZjcyZDQtY2UyOGQ0ODJjNi00ZWY4ZDAifQ.j-w5jk5Ji-0vCkaxVaK8pDMIOhRsXmG7o6oZictoHYE">Huly®: <b>ENG-1057</b></a></sub>
175 lines
4.0 KiB
Plaintext
175 lines
4.0 KiB
Plaintext
@go.Package { name = "github.com/onsonr/sonr/internal/orm/transactions" }
|
|
|
|
module transactions
|
|
|
|
import "package://pkg.pkl-lang.org/pkl-go/pkl.golang@0.5.0#/go.pkl"
|
|
|
|
/// Common Cosmos SDK types
|
|
typealias Coin = Dynamic
|
|
typealias AccAddress = String
|
|
typealias ValAddress = String
|
|
typealias Timestamp = String
|
|
|
|
/// Base class for all messages
|
|
abstract class Msg {
|
|
/// The type URL for the message
|
|
typeUrl: String
|
|
}
|
|
|
|
/// Base class for all proposals
|
|
class Proposal {
|
|
/// The title of the proposal
|
|
title: String
|
|
|
|
/// The description of the proposal
|
|
description: String
|
|
}
|
|
|
|
/// Gov module messages
|
|
class MsgGovSubmitProposal extends Msg {
|
|
typeUrl = "/cosmos.gov.v1beta1.MsgSubmitProposal"
|
|
content: Proposal
|
|
initialDeposit: List<Coin>
|
|
proposer: AccAddress
|
|
}
|
|
|
|
class MsgGovVote extends Msg {
|
|
typeUrl = "/cosmos.gov.v1beta1.MsgVote"
|
|
proposalId: Int
|
|
voter: AccAddress
|
|
option: Int
|
|
}
|
|
|
|
class MsgGovDeposit extends Msg {
|
|
typeUrl = "/cosmos.gov.v1beta1.MsgDeposit"
|
|
proposalId: Int
|
|
depositor: AccAddress
|
|
amount: List<Coin>
|
|
}
|
|
|
|
/// Group module messages
|
|
class MsgGroupCreateGroup extends Msg {
|
|
typeUrl = "/cosmos.group.v1.MsgCreateGroup"
|
|
admin: AccAddress
|
|
members: List<Dynamic>
|
|
metadata: String
|
|
}
|
|
|
|
class MsgGroupSubmitProposal extends Msg {
|
|
typeUrl = "/cosmos.group.v1.MsgSubmitProposal"
|
|
groupPolicyAddress: AccAddress
|
|
proposers: List<AccAddress>
|
|
metadata: String
|
|
messages: List<Dynamic>
|
|
exec: Int
|
|
}
|
|
|
|
class MsgGroupVote extends Msg {
|
|
typeUrl = "/cosmos.group.v1.MsgVote"
|
|
proposalId: Int
|
|
voter: AccAddress
|
|
option: Int
|
|
metadata: String
|
|
exec: Int
|
|
}
|
|
|
|
/// Staking module messages
|
|
class MsgStakingCreateValidator extends Msg {
|
|
typeUrl = "/cosmos.staking.v1beta1.MsgCreateValidator"
|
|
description: Dynamic
|
|
commission: Dynamic
|
|
minSelfDelegation: String
|
|
delegatorAddress: AccAddress
|
|
validatorAddress: ValAddress
|
|
pubkey: Dynamic
|
|
value: Coin
|
|
}
|
|
|
|
class MsgStakingDelegate extends Msg {
|
|
typeUrl = "/cosmos.staking.v1beta1.MsgDelegate"
|
|
delegatorAddress: AccAddress
|
|
validatorAddress: ValAddress
|
|
amount: Coin
|
|
}
|
|
|
|
class MsgStakingUndelegate extends Msg {
|
|
typeUrl = "/cosmos.staking.v1beta1.MsgUndelegate"
|
|
delegatorAddress: AccAddress
|
|
validatorAddress: ValAddress
|
|
amount: Coin
|
|
}
|
|
|
|
class MsgStakingBeginRedelegate extends Msg {
|
|
typeUrl = "/cosmos.staking.v1beta1.MsgBeginRedelegate"
|
|
delegatorAddress: AccAddress
|
|
validatorSrcAddress: ValAddress
|
|
validatorDstAddress: ValAddress
|
|
amount: Coin
|
|
}
|
|
class MsgDidUpdateParams extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgUpdateParams"
|
|
authority: AccAddress
|
|
params: Dynamic
|
|
token: Dynamic
|
|
}
|
|
|
|
class MsgDidAllocateVault extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgAllocateVault"
|
|
authority: AccAddress
|
|
subject: String
|
|
token: Dynamic
|
|
}
|
|
|
|
class MsgDidProveWitness extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgProveWitness"
|
|
authority: AccAddress
|
|
property: String
|
|
witness: Listing<Int>
|
|
token: Dynamic
|
|
}
|
|
|
|
class MsgDidSyncVault extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgSyncVault"
|
|
controller: AccAddress
|
|
token: Dynamic
|
|
}
|
|
|
|
class MsgDidRegisterController extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgRegisterController"
|
|
authority: AccAddress
|
|
cid: String
|
|
origin: String
|
|
authentication: List<Dynamic>
|
|
token: Dynamic
|
|
}
|
|
|
|
class MsgDidAuthorize extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgAuthorize"
|
|
authority: AccAddress
|
|
controller: AccAddress
|
|
address: AccAddress
|
|
origin: String
|
|
token: Dynamic
|
|
}
|
|
|
|
class MsgDidRegisterService extends Msg {
|
|
typeUrl = "/sonr.did.v1.MsgRegisterService"
|
|
controller: AccAddress
|
|
originUri: String
|
|
scopes: Dynamic
|
|
description: String
|
|
serviceEndpoints: Map<String, String>
|
|
metadata: Dynamic
|
|
token: Dynamic
|
|
}
|
|
|
|
/// Represents a transaction body
|
|
class TxBody {
|
|
messages: List<Msg>
|
|
memo: String?
|
|
timeoutHeight: Int?
|
|
extensionOptions: List<Dynamic>?
|
|
nonCriticalExtensionOptions: List<Dynamic>?
|
|
}
|
|
|