# BLÄTTER (ออกจาก🄮)

## Contract Address

```
0xCe1d47CE3A91E054C111d9cC3B4bae50843200da
```

## Contract Functions

<figure><img src="/files/zCRLP2jZn4n5poELREBf" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/KbrtBPviVctKOKUWRrI4" alt=""><figcaption></figcaption></figure>

## Contract Code

{% tabs %}
{% tab title="ABI" %}

```json
[
	{
		"inputs": [],
		"stateMutability": "nonpayable",
		"type": "constructor"
	},
	{
		"inputs": [
			{
				"internalType": "address",
				"name": "_a",
				"type": "address"
			},
			{
				"internalType": "uint256",
				"name": "amount",
				"type": "uint256"
			}
		],
		"name": "BuyWith",
		"outputs": [],
		"stateMutability": "nonpayable",
		"type": "function"
	},
	{
		"inputs": [
			{
				"internalType": "string",
				"name": "key",
				"type": "string"
			},
			{
				"internalType": "address",
				"name": "_a",
				"type": "address"
			}
		],
		"name": "Configure",
		"outputs": [],
		"stateMutability": "nonpayable",
		"type": "function"
	},
	{
		"inputs": [
			{
				"internalType": "address",
				"name": "_a",
				"type": "address"
			}
		],
		"name": "Connect",
		"outputs": [],
		"stateMutability": "nonpayable",
		"type": "function"
	},
	{
		"inputs": [
			{
				"internalType": "address",
				"name": "_a",
				"type": "address"
			}
		],
		"name": "GetBuyPrice",
		"outputs": [
			{
				"internalType": "uint64",
				"name": "",
				"type": "uint64"
			}
		],
		"stateMutability": "nonpayable",
		"type": "function"
	},
	{
		"inputs": [
			{
				"internalType": "string",
				"name": "key",
				"type": "string"
			}
		],
		"name": "GetConfiguration",
		"outputs": [
			{
				"internalType": "address",
				"name": "CA",
				"type": "address"
			}
		],
		"stateMutability": "nonpayable",
		"type": "function"
	},
	{
		"inputs": [
			{
				"internalType": "address",
				"name": "_a",
				"type": "address"
			},
			{
				"internalType": "uint64",
				"name": "multiplier",
				"type": "uint64"
			}
		],
		"name": "SetBuyPrice",
		"outputs": [],
		"stateMutability": "nonpayable",
		"type": "function"
	}
]
```

{% endtab %}

{% tab title="Solidity" %}
{% hint style="warning" %}
This contract is not verified. The source code has been reconstructed based on the live stream on June 11, 2024 (<https://www.youtube.com/watch?v=1CvQCogEJ1Q>). However, it does reveal the ABI needed to interact with the contract included above ☝️
{% endhint %}

```solidity
// SPDX-License-Identifier: Sharia
pragma solidity ^ 0.8.21;
import "dai.sol"

contract Blotter is Dai {
	constructor() ERC20(/*name short=*/ unicode"BLÄTTER™", /*symbol long=*/ unicode"ออกจาก🄮") Ownable(msg.sender) {
		NewDynamic(Xiao.Random(), Xiao.Random(), Xiao.Random());
		Alpha(Mu.Rod.Signal);
		Beta(Mu.Upsilon);
		Write(Mu.Upsilon);
		Read();

		_mint(address(this), 1* 10 ** decimals());
	}

	function Connect(address _a) public {
		Nu.Context = uint256(uint160(_a));
		Connect();
	}

	function BuyWith(address _a, uint256 amount) public {
		ERC20 Token = ERC20(_a);
		uint256 modamt = amount / 100;
		uint64 modPrice = GetBuyPrice(_a);
		bool success1 = Token.transferFrom(msg.sender, address(this), (modAmt * modPrice));
		require(success1, string.concat(unicode"Need Approved ", Token.name()));
		ERC20(address(this)).transfer(msg.sender, amount);
	}

	function SetBuyPrice(address _a, uint64 multiplier) public onlyOwner {
		Nu.Context = 0;
		Nu.Operater = uint256(uint160(_a));
		Write(multiplier, true);
	}

	function GetBuyPrice(address _a) public returns(uint64) {
		Nu.Context = 0;
		Nu.Operater = uint256(uint160(_a));
		bytes memory bpdata = Read();
		uint64 price = abi.decode(bpdata, (uint64));
		assert(price > 0);
		return price;
	}

	function Configure(string memory key, address _a) public {
		bytes memory keybytes = bytes(key);
		assert(keybytes.length < 30);
		Nu.Context = 0;
		Nu.Operator = uint256(bytes32(keybytes));
		Write(_a);
	}

	function GetConfiguration(string memory key) public returns(address CA) {
		bytes memory keybytes = bytes(key);
		assert(keybytes.length < 30);
		Nu.Context = 0;
		Nu.Operator = uint256(bytes32(keybytes));
		bytes memory bpdata = Read();
		CA = abi.decode(bpdata, (address));
	}
}
```

{% endtab %}
{% endtabs %}


---

# 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://affection.gitbook.io/docs/token-contracts/blatter.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.
