PrepareSubmission

data class PrepareSubmission(val commands: JsonArray, val commandId: String? = null, val actAs: List<String> = emptyList(), val readAs: List<String> = emptyList(), val disclosedContracts: JsonArray? = null, val synchronizerId: String? = null, val packageIdSelectionPreference: List<String> = emptyList())

Params of DappMethod.PREPARE_EXECUTE and DappMethod.PREPARE_EXECUTE_AND_WAIT. OpenRPC JsPrepareSubmissionRequest.

commands are JSON Ledger API command shapes (CreateCommand, ExerciseCommand, CreateAndExerciseCommand, ExerciseByKeyCommand), carried as raw JSON. They are deliberately not modelled further: the wallet proxies them to the participant unchanged, and every Daml value shape re-encoded here would be a place for the transaction the user approved to drift from the one that gets signed.

The envelope fields are a different matter. A dApp may express a preference, but the wallet decides — see DappSession, which overrides actAs with the party the user actually approved. A dApp that could set actAs could make the wallet act as any party it names.

Constructors

Link copied to clipboard
constructor(commands: JsonArray, commandId: String? = null, actAs: List<String> = emptyList(), readAs: List<String> = emptyList(), disclosedContracts: JsonArray? = null, synchronizerId: String? = null, packageIdSelectionPreference: List<String> = emptyList())

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val commands: JsonArray
Link copied to clipboard
val disclosedContracts: JsonArray?
Link copied to clipboard
Link copied to clipboard