Questions tagged [smart-contract]

A digital agreement that specifies where funds/tokens/assets should go, and under what conditions they will be sent, executing a deal only when all the conditions are met.

Filter by
Sorted by
Tagged with
20 votes
6 answers
974 views

General approach for allowing multiple smart contract transactions per block

In some applications, multiple users interact with the same smart contract and may want to do it at about the same time. Such interaction involves updating the state of the smart contract as embodied ...
user avatar
  • 1,285
16 votes
5 answers
1k views

What is a Redeemer?

So I am currently on lecture 1 on the Plutus Pioneer Program. In the lecture they said the redeemer is the input information that the script uses to decide if a specific UTxO can be spent. I watched a ...
user avatar
14 votes
6 answers
2k views

The Concurrency Issue

Are there any solutions to the concurrency issue so far without sacrificing decentralization? MinSwap testnet was experiencing this last night and just looking for some clarification, haven't seen ...
user avatar
  • 221
12 votes
1 answer
570 views

Where is stored off-chain code?

As I understand, a smart contract in Cardano contains on-chain code and off-chain code. On-chain code is executed by cardano nodes in order to validate transaction. Off-chain code builds a ...
user avatar
  • 1,654
9 votes
2 answers
478 views

Is there a good tutorial to mint Cardano NFT using plutus script?

I used to mint Cardano NFT using "Time locking" following this guide https://developers.cardano.org/docs/native-tokens/minting-nfts/. But I know the more formal way is to use plutus script ...
user avatar
16 votes
3 answers
417 views

What's the difference between "on-chain" and "off-chain" in plutus smart contracts?

Smart contracts written in Plutus can be divided in two: an on-chain part and an off-chain part. What's the main difference between these two?
user avatar
14 votes
2 answers
905 views

Where does a smart contract exist, in EUTxO?

In particular, I want to know whether the smart contract is somehow its own entity in the blockchain, or if a smart contract is just a property that EUTxOs may pick up. EUTxOs are bound by smart ...
user avatar
7 votes
4 answers
185 views

How can an oracle guarantee certain update rates respectively uptime?

After reading the question General approach for allowing multiple smart contract transactions per block I'm wondering how an oracle can guarantee update rates respectively uptime. If too many ...
user avatar
3 votes
1 answer
223 views

What's the difference between programmable validators and smart contracts?

Charles Hoskinson indicated in this tweet that he favors the term "programmable validator" to the term "smart contract" with regard to Cardano. Quoting the tweet Charles Hoskinson ...
user avatar
  • 133
2 votes
1 answer
108 views

Getting the address of a parameterized contract from within the validator of another script

Suppose I have one contract, Contract 1, that is parameterized by type Contract1Params{ tokenName :: BuiltinByteString } and I have a minting policy that will only mint a token with tokenName tn ...
user avatar
22 votes
1 answer
253 views

Randomness in a smart contract

Is it possible to get randomness in a smart contract? E.g. I would like the validator to randomly choose between two conditions to use to validate a transaction. Such a capability could be used for ...
user avatar
  • 1,285
9 votes
2 answers
378 views

What is the maximum number of contracts Cardano can store?

I see Ethereum (ETH) can store 2256 smart contracts, so is there any description about this for Cardano, i.e. how many contracts can Cardano store?
user avatar
1 vote
1 answer
99 views

Can you manually list an address in a Smart Contract

Can you manually list a wallet address in a smart contract transaction? For example lets say I create a smart contract that allows any user to send Ada to a specific address by sending it to the ...
user avatar
  • 456
7 votes
2 answers
140 views

Referencing onchain contract as 3rd party

In solidity and EVM, it is possible to reference external contracts by providing the address and interface to the contract: address ckAddress = 0x06012c8cf97BEaD5deAe237070F9587f8E7A266d; ...
user avatar
  • 161
5 votes
1 answer
190 views

Change minted tokens recepient

I am trying to create a dApp in which "accounts" are authenticated using a minting policy script. It should work by only allowing the minting of tokens if they are sent to an arbitrary ...
user avatar
  • 773
5 votes
1 answer
81 views

Should I hold ADA as company to pay fees and issue Native Tokens for my game?

As far I know Carano will allow to pay fees in Native Tokens, so fees will be on ADA + a reward. But I have questions about it after reading this blog post from IOHK. If I'm running the economy of my ...
user avatar
4 votes
1 answer
148 views

How do I make a Sidechain

I want to make a side chain on Cardano to so something that the protocol says should be done on a sidechain, but how do I make one? Can I use Plutus or am I limited to the CLI?
user avatar
4 votes
3 answers
441 views

How to generate the address of a plutus script using Cardano Serialization Lib?

I am sending some smart contracts using the Cardano Serialization Lib and the nami wallet for signing, everything works fine, but I am not able to get the script address of a Plutus Script. I have ...
user avatar
3 votes
2 answers
486 views

Can a smart contract only be interacted with once

Im confused if a eUTXO can only be interacted with and used up once how can you do a NFT sale? If I were to make a smart contract to distribute NFT's from a wallet can that be interacted with by ...
user avatar
  • 456
2 votes
1 answer
129 views

Referencing an external plutus script

I would like to understand how one can reference an external plutus script in one transaction. In solidity (for the other script), one can import the contract interface into their script, create an ...
user avatar
  • 21
2 votes
1 answer
42 views

How to Make Sure A Contract Is Signed By a Certain Party?

I'm thinking about making a parameterised contract between two users. User A can be anyone i.e. any customer, But User B should always be the company. I want to make it so that the validator only ...
user avatar
1 vote
0 answers
117 views

User interaction with smart contracts

I want my users to interact with my smart contracts. All transactions come from these users. There are no transactions - except for setting up - that come from my wallets. As entry point for this ...
user avatar
  • 1,356
0 votes
1 answer
146 views

NativeScript vs PlutusScript

In cardano serialization lib what is the difference between NativeScript and PlutusScript? Is there a way to convert from one to the other? I'm trying to load a minting policy script I made as a ...
user avatar
  • 773