.derupt-profile

Derupt users need their own .derupt-profile contract on Stacks Mainnet. (deployed & activated in app)

General:

  • A distinct .derupt-profile contract should be deployed and activated per user.

  • .derupt-profile contract calls the .derupt-core-yyyymmdd contract for application logic purposes

Warning:

  • users should deploy a .derupt-profilecontract in app to interact with core features.

  • users should call.derupt-profile

  • users should not call.derupt-core-yyyymmdd (nor logging contracts)

Functions Process Transactions Overview:

What happens in a process depends on the function the user is calling.

  • send-message: mine-citycoin is called during this process.

  • like-message: transfer-citycoin is called during this process.

  • dislike-message: stack-citycoin is called during this process.

  • favorable-reply-message: mine-citycoin & transfer-citycoin is called during this process.

  • unfavorable-reply-message: mine-citycoin & stack-citycoin is called during this process.

The five main functions and arguments in a .derupt-profilecontract:

send-message

Broadcast Send Message to the Stacks Blockchain

Data Flow of the Function: 1).derupt-profile 2).derupt-core-yyyymmdd 3).derupt-feed (&.derupt-miners)

Arguments:

  • content

    • required || string-utf8 || Max: 256 || Message Body

  • attachment-uri

    • optional || string-utf8 || Max: 256 || Message Attachment (example: 'bns://1679121920338.mp3')

  • thumbnail-uri

    • optional || string-utf8 || Max: 256 || Attachment Preview (example: 'bns://1679121920589.png')

  • reply-to

    • optional || string-utf8 || Max: 256 || Stacks Transaction ID

  • cityName

    • required || string-ascii || Max: 10 || Example: 'mia' or 'nyc'

  • alt-origin

    • required || string-utf8 || Max: 256 || Alternative Origin

  • extras

    • optional || tuple || Max: 256 (per) || 10 Additional Arguments

  • core-contract

    • required || trait_reference || trait_reference || Derupt Core Contract Reference

Responses:

  • Successful Stacks Transaction

  • Unsuccessful Stacks Transaction

like-message

Broadcast Like Message to Stacks Blockchain

Data Flow of the Function: 1) .derupt-profile 2) .derupt-core-yyyymmdd 3) .derupt-sentiments

Arguments:

  • author-principal

    • required || principal || principal || The Liked Message Author Principal

  • liked-txid

    • required || string-utf8 || Max: 256 || Stacks Transaction ID (of Liked Message)

  • contractId

    • required || trait_reference || trait_reference || CityCoin Contract Reference

  • core-contract

    • required || trait_reference || trait_reference || Derupt Core Contract Reference

Responses:

  • Successful Stacks Transaction

  • Unsuccessful Stacks Transaction

dislike-message

Broadcast Dislike Message to Stacks Blockchain

Data Flow of the Function: 1) .derupt-profile 2) .derupt-core-yyyymmdd 3) .derupt-sentiments (&.derupt-stackers)

Arguments:

  • author-principal

    • required || principal || principal || The Liked Message Author Principal

  • disliked-txid

    • required || string-utf8 || Max: 256 || Stacks Transaction ID (of Disliked Message)

  • cityName

    • required || string-ascii || Max: 10 || Example: 'mia' or 'nyc'

  • contractId

    • required || trait_reference || trait_reference || CityCoin Contract Reference

  • core-contract

    • required || trait_reference || trait_reference || Derupt Core Contract Reference

Responses:

  • Successful Stacks Transaction

  • Unsuccessful Stacks Transaction

favorable-reply-message

Broadcast Favorable Reply Message to Stacks Blockchain

Data Flow of the Function: 1) .derupt-profile 2) .derupt-core-yyyymmdd 3) .derupt-feed (&.derupt-sentiments &.derupt-miners)

Arguments:

  • content

    • required || string-utf8 || Max: 256 || Message Body

  • attachment-uri

    • optional || string-utf8 || Max: 256 || Message Attachment (example: 'bns://1679121920338.mp3')

  • thumbnail-uri

    • optional || string-utf8 || Max: 256 || Attachment Preview (example: 'bns://1679121920589.png')

  • reply-to

    • optional || string-utf8 || Max: 256 || Stacks Transaction ID

  • author-principal

    • required || principal || principal || The Liked Message Author Principal

  • liked-txid

    • required || string-utf8 || Max: 256 || Stacks Transaction ID (of Liked Message)

  • cityName

    • required || string-ascii || Max: 10 || Example: 'mia' or 'nyc'

  • alt-origin

    • required || string-utf8 || Max: 256 || Alternative Origin

  • extras

    • optional || tuple || Max: 256 (per) || 10 Additional Arguments

  • contractId

    • required || trait_reference || trait_reference || CityCoin Contract Reference

  • core-contract

    • required || trait_reference || trait_reference || Derupt Core Contract Reference

Responses:

  • Successful Stacks Transaction

  • Unsuccessful Stacks Transaction

unfavorable-reply-message

Broadcast Unfavorable Reply Message to Stacks Blockchain

Data Flow of the Function: 1) .derupt-profile 2) .derupt-core-yyyymmdd 3) .derupt-feed (&.derupt-sentiments &.derupt-miners &.derupt-stackers)

Arguments:

  • content

    • required || string-utf8 || Max: 256 || Message Body

  • attachment-uri

    • optional || string-utf8 || Max: 256 || Message Attachment (example: 'bns://1679121920338.mp3')

  • thumbnail-uri

    • optional || string-utf8 || Max: 256 || Attachment Preview (example: 'bns://1679121920589.png')

  • reply-to

    • optional || string-utf8 || Max: 256 || Stacks Transaction ID

  • author-principal

    • required || principal || principal || The Liked Message Author Principal

  • disliked-txid

    • required || string-utf8 || Max: 256 || Stacks Transaction ID (of Disliked Message)

  • cityName

    • required || string-ascii || Max: 10 || Example: 'mia' or 'nyc'

  • alt-origin

    • required || string-utf8 || Max: 256 || Alternative Origin

  • extras

    • optional || tuple || Max: 256 (per) || 10 Additional Arguments

  • contractId

    • required || trait_reference || trait_reference || CityCoin Contract Reference

  • core-contract

    • required || trait_reference || trait_reference || Derupt Core Contract Reference

Responses:

  • Successful Stacks Transaction

  • Unsuccessful Stacks Transaction

Last updated