Smart Contracts (Testnet)

Module: carbon_credit_market
back to overview
carbon_credit_market
Methods: 21
Instances: 2
Initialization

Parameters
{
  "commission": "<UInt16>"
}
Errors
{
  "Enum": [
    {
      "ParseParams": []
    },
    {
      "CalledByAContract": []
    },
    {
      "TokenNotListed": []
    },
    {
      "Cis2ClientError": [
        {
          "Enum": [
            {
              "InvokeContractError": []
            },
            {
              "ParseParams": []
            },
            {
              "ParseResult": []
            },
            {
              "CollectionNotCis2": []
            }
          ]
        }
      ]
    },
    {
      "InvalidAmountPaid": []
    },
    {
      "InvokeTransferError": []
    },
    {
      "NoBalance": []
    },
    {
      "InvalidCommission": []
    },
    {
      "InvalidTokenQuantity": []
    },
    {
      "InvalidRoyalty": []
    },
    {
      "TokenNotInCustody": []
    },
    {
      "CalledByAnAccount": []
    },
    {
      "LogError": []
    }
  ]
}
Event
{
  "Enum": [
    {
      "TokenReceived": [
        {
          "amount": "<String of size at most 74 containing an unsigned integer.>",
          "owner": {
            "Enum": [
              {
                "Account": [
                  "<AccountAddress>"
                ]
              },
              {
                "Contract": [
                  {
                    "index": "<UInt64>",
                    "subindex": "<UInt64>"
                  }
                ]
              }
            ]
          },
          "token_contract": {
            "index": "<UInt64>",
            "subindex": "<UInt64>"
          },
          "token_id": "<String with lowercase hex>"
        }
      ]
    },
    {
      "TokenListed": [
        {
          "amount": "<String of size at most 74 containing an unsigned integer.>",
          "price": "<Amount in microCCD>",
          "token_contract": {
            "index": "<UInt64>",
            "subindex": "<UInt64>"
          },
          "token_id": "<String with lowercase hex>"
        }
      ]
    },
    {
      "TokenTransferred": [
        {
          "amount": "<String of size at most 74 containing an unsigned integer.>",
          "from": {
            "Enum": [
              {
                "Account": [
                  "<AccountAddress>"
                ]
              },
              {
                "Contract": [
                  {
                    "index": "<UInt64>",
                    "subindex": "<UInt64>"
                  }
                ]
              }
            ]
          },
          "to": {
            "Enum": [
              {
                "Account": [
                  "<AccountAddress>"
                ]
              },
              {
                "Contract": [
                  {
                    "index": "<UInt64>",
                    "subindex": "<UInt64>"
                  }
                ]
              }
            ]
          },
          "token_contract": {
            "index": "<UInt64>",
            "subindex": "<UInt64>"
          },
          "token_id": "<String with lowercase hex>"
        }
      ]
    }
  ]
}
Methods

Parameters
None
Errors
None
Return
None

Parameters
None
Errors
None
Return
None

Parameters
None
Errors
None
Return
None

Parameters
None
Errors
None
Return
None

Parameters
None
Errors
None
Return
None

Parameters
None
Errors
None
Return
None

Parameters
{
  "cis_contract_address": {
    "index": "<UInt64>",
    "subindex": "<UInt64>"
  },
  "owner": "<AccountAddress>",
  "quantity": "<String of size at most 74 containing an unsigned integer.>",
  "to": "<AccountAddress>",
  "token_id": "<String with lowercase hex>"
}
Errors
{
  "Enum": [
    {
      "ParseParams": []
    },
    {
      "CalledByAContract": []
    },
    {
      "TokenNotListed": []
    },
    {
      "Cis2ClientError": [
        {
          "Enum": [
            {
              "InvokeContractError": []
            },
            {
              "ParseParams": []
            },
            {
              "ParseResult": []
            },
            {
              "CollectionNotCis2": []
            }
          ]
        }
      ]
    },
    {
      "InvalidAmountPaid": []
    },
    {
      "InvokeTransferError": []
    },
    {
      "NoBalance": []
    },
    {
      "InvalidCommission": []
    },
    {
      "InvalidTokenQuantity": []
    },
    {
      "InvalidRoyalty": []
    },
    {
      "TokenNotInCustody": []
    },
    {
      "CalledByAnAccount": []
    },
    {
      "LogError": []
    }
  ]
}
Return
None

Parameters
None
Errors
None
Return
None

Parameters
None
Errors
{
  "Enum": [
    {
      "ParseParams": []
    },
    {
      "CalledByAContract": []
    },
    {
      "TokenNotListed": []
    },
    {
      "Cis2ClientError": [
        {
          "Enum": [
            {
              "InvokeContractError": []
            },
            {
              "ParseParams": []
            },
            {
              "ParseResult": []
            },
            {
              "CollectionNotCis2": []
            }
          ]
        }
      ]
    },
    {
      "InvalidAmountPaid": []
    },
    {
      "InvokeTransferError": []
    },
    {
      "NoBalance": []
    },
    {
      "InvalidCommission": []
    },
    {
      "InvalidTokenQuantity": []
    },
    {
      "InvalidRoyalty": []
    },
    {
      "TokenNotInCustody": []
    },
    {
      "CalledByAnAccount": []
    },
    {
      "LogError": []
    }
  ]
}
Return
None

Parameters
{
  "cis_contract_address": {
    "index": "<UInt64>",
    "subindex": "<UInt64>"
  },
  "price": "<Amount in microCCD>",
  "royalty": "<UInt16>",
  "token_id": "<String with lowercase hex>"
}
Errors
{
  "Enum": [
    {
      "ParseParams": []
    },
    {
      "CalledByAContract": []
    },
    {
      "TokenNotListed": []
    },
    {
      "Cis2ClientError": [
        {
          "Enum": [
            {
              "InvokeContractError": []
            },
            {
              "ParseParams": []
            },
            {
              "ParseResult": []
            },
            {
              "CollectionNotCis2": []
            }
          ]
        }
      ]
    },
    {
      "InvalidAmountPaid": []
    },
    {
      "InvokeTransferError": []
    },
    {
      "NoBalance": []
    },
    {
      "InvalidCommission": []
    },
    {
      "InvalidTokenQuantity": []
    },
    {
      "InvalidRoyalty": []
    },
    {
      "TokenNotInCustody": []
    },
    {
      "CalledByAnAccount": []
    },
    {
      "LogError": []
    }
  ]
}
Return
None

Parameters
None
Errors
{
  "Enum": [
    {
      "ParseParams": []
    },
    {
      "CalledByAContract": []
    },
    {
      "TokenNotListed": []
    },
    {
      "Cis2ClientError": [
        {
          "Enum": [
            {
              "InvokeContractError": []
            },
            {
              "ParseParams": []
            },
            {
              "ParseResult": []
            },
            {
              "CollectionNotCis2": []
            }
          ]
        }
      ]
    },
    {
      "InvalidAmountPaid": []
    },
    {
      "InvokeTransferError": []
    },
    {
      "NoBalance": []
    },
    {
      "InvalidCommission": []
    },
    {
      "InvalidTokenQuantity": []
    },
    {
      "InvalidRoyalty": []
    },
    {
      "TokenNotInCustody": []
    },
    {
      "CalledByAnAccount": []
    },
    {
      "LogError": []
    }
  ]
}
Return
[
  [
    {
      "contract": {
        "index": "<UInt64>",
        "subindex": "<UInt64>"
      },
      "owner": "<AccountAddress>",
      "price": "<Amount in microCCD>",
      "primary_owner": "<AccountAddress>",
      "quantity": "<String of size at most 74 containing an unsigned integer.>",
      "royalty": "<UInt16>",
      "token_id": "<String with lowercase hex>"
    }
  ]
]

Parameters
None
Errors
{
  "Enum": [
    {
      "ParseParams": []
    },
    {
      "CalledByAContract": []
    },
    {
      "TokenNotListed": []
    },
    {
      "Cis2ClientError": [
        {
          "Enum": [
            {
              "InvokeContractError": []
            },
            {
              "ParseParams": []
            },
            {
              "ParseResult": []
            },
            {
              "CollectionNotCis2": []
            }
          ]
        }
      ]
    },
    {
      "InvalidAmountPaid": []
    },
    {
      "InvokeTransferError": []
    },
    {
      "NoBalance": []
    },
    {
      "InvalidCommission": []
    },
    {
      "InvalidTokenQuantity": []
    },
    {
      "InvalidRoyalty": []
    },
    {
      "TokenNotInCustody": []
    },
    {
      "CalledByAnAccount": []
    },
    {
      "LogError": []
    }
  ]
}
Return
[
  {
    "contract": {
      "index": "<UInt64>",
      "subindex": "<UInt64>"
    },
    "owner": "<AccountAddress>",
    "quantity": "<String of size at most 74 containing an unsigned integer.>",
    "token_id": "<String with lowercase hex>"
  }
]


Release: 2024.12
Support CCDExplorer.io Uptime Backend Status CCDExplorer is supported by AesirX - Decentralized Consent & Data Ownership