Skip to content

Instantly share code, notes, and snippets.

@piccasso73
Created September 30, 2022 04:33
Show Gist options
  • Select an option

  • Save piccasso73/0dc4f74232eda30e55fb846f8ebddf89 to your computer and use it in GitHub Desktop.

Select an option

Save piccasso73/0dc4f74232eda30e55fb846f8ebddf89 to your computer and use it in GitHub Desktop.
SwapContract
{"valueParameterInfo":[["Amount of Ada",{"valueParameterFormat":{"contents":[0,"₳"],"tag":"DecimalFormat"},"valueParameterDescription":"Amount of Ada to be exchanged for dollars."}],["Amount of dollars",{"valueParameterFormat":{"contents":[0,"$"],"tag":"DecimalFormat"},"valueParameterDescription":"Amount of dollar tokens to be exchanged for Ada."}]],"timeParameterDescriptions":[["Timeout for Ada deposit","Deadline by which Ada must be deposited."],["Timeout for dollar deposit","Deadline by which dollar tokens must be deposited (must be after the deadline for Ada deposit)."]],"roleDescriptions":[["Ada provider","The party that provides the Ada."],["Dollar provider","The party that provides the dollar tokens."]],"contractType":"Swap","contractShortDescription":"Atomically exchange of Ada and dollar tokens.","contractName":"Swap of Ada and dollar tokens","contractLongDescription":"Waits until one party deposits Ada and the other party deposits dollar tokens. If both parties collaborate it carries the exchange atomically, otherwise parties are refunded.","choiceInfo":[]}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment