The factory contract can create instances of the Terraswap Pair contract. It is also used as a directory contract for all pools ever created.
The Factory is permissioned.
{
"pair_code_id": 123,
"token_code_id": 123,
"fee_collector_addr": "juno1..."
}
{
"update_config": {
"owner": "juno1...",
"fee_collector_addr": "juno1...",
"token_id": 123,
"pair_code_id": 123
}
}
{
"create_pair": {
"asset_infos": [
{
"token": {
"contract_addr": "juno1..."
}
},
{
"native_token": {
"denom": "ujuno"
}
}
]
}
}
{
"add_native_token_decimals": {
"denom": "ujuno",
"decimals": 6
}
}
{
"config": {}
}
{
"pair": {
"asset_infos": [
{
"token": {
"contract_addr": "juno1..."
}
},
{
"native_token": {
"denom": "ujuno"
}
}
]
}
}
{
"pairs": {
"start_after": [
{
"token": {
"contract_addr": "juno1..."
}
},
{
"native_token": {
"denom": "ujuno"
}
}
],
"limit": 30
}
}
{
"native_token_decimals": {
"denom": "ujuno"
}
}