# .derupt-profile

{% hint style="info" %}
**General:**

* A distinct **.derupt-profile** contract should be deployed and activated per user.&#x20;
* **.derupt-profile** contract calls the **.derupt-core-yyyymmdd** contract for application logic purposes
  {% endhint %}

{% hint style="warning" %}
**Warning:**

* **users should deploy a** `.derupt-profile`contract in app to interact with core features.
* **users should call**`.derupt-profile`
* **users should not call**`.derupt-core-yyyymmdd (nor logging contracts)`
  {% endhint %}

{% hint style="info" %}
**Functions Process Transactions Overview:**

What happens in a process depends on the function the user is calling.&#x20;

* **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.&#x20;
  {% endhint %}

The five main functions and arguments in a `.derupt-profile`contract:

<details>

<summary><mark style="color:orange;">send-message</mark> </summary>

<mark style="color:orange;">Broadcast Send Message to the Stacks Blockchain</mark>

**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*&#x20;
* core-contract
  * required || trait\_reference || trait\_reference || *Derupt Core Contract Reference*&#x20;

**Responses:**

* Successful Stacks Transaction
* Unsuccessful Stacks Transaction

</details>

<details>

<summary><mark style="color:orange;">like-message</mark></summary>

<mark style="color:orange;">Broadcast Like Message to Stacks Blockchain</mark>

**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*&#x20;

**Responses:**

* Successful Stacks Transaction
* Unsuccessful Stacks Transaction

</details>

<details>

<summary><mark style="color:orange;">dislike-message</mark></summary>

<mark style="color:orange;">Broadcast Dislike Message to Stacks Blockchain</mark>

**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*&#x20;

**Responses:**

* Successful Stacks Transaction
* Unsuccessful Stacks Transaction

</details>

<details>

<summary><mark style="color:orange;">favorable-reply-message</mark></summary>

<mark style="color:orange;">Broadcast Favorable Reply Message to Stacks Blockchain</mark>

**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

</details>

<details>

<summary><mark style="color:orange;">unfavorable-reply-message</mark></summary>

<mark style="color:orange;">Broadcast Unfavorable Reply Message to Stacks Blockchain</mark>

**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

</details>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.derupt.io/legacy/contracts-legacy/.derupt-profile.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
