save
This commit is contained in:
parent
9dd442e716
commit
68a3d9fe3c
7
.envrc
7
.envrc
@ -1,2 +1,7 @@
|
||||
export COMPOSE_DOCKER_CLI_BUILD=1
|
||||
export DOCKER_BUILDKIT=1
|
||||
export DOCKER_BUILDKIT=1
|
||||
export TOKEN_TYPE=giftable_erc20_token
|
||||
export TOKEN_NAME=Coffee
|
||||
export TOKEN_SYMBOL=COFE
|
||||
export TOKEN_DECIMALS=6
|
||||
export FAUCET_AMOUNT=30000000000
|
@ -207,13 +207,25 @@ mutation {
|
||||
}
|
||||
|
||||
"""
|
||||
# m_result = schema.execute(mutation_with_argument)
|
||||
# print(m_result)
|
||||
m_result = schema.execute(mutation_with_argument)
|
||||
print(m_result.data)
|
||||
address_1 = "0xde82da08c816865c24a2c9c76a2bcd44b5b94531" #m_result.data['createAccount']['address']
|
||||
|
||||
mutation_with_argument = """
|
||||
mutation {
|
||||
createAccount(password:"test"){
|
||||
address
|
||||
}
|
||||
}
|
||||
|
||||
"""
|
||||
m_result = schema.execute(mutation_with_argument)
|
||||
print(m_result)
|
||||
address_2 = "0xaee24c8af3249b2d0a26769286623fff00556788" #m_result.data['createAccount']['address']
|
||||
|
||||
balance_query = """
|
||||
query {
|
||||
balance(address:"0x82e66cf2766bf20672a605bbf5a6faaa12d5b907", tokenSymbols:["GFT"]){
|
||||
query getBalance($address:String){
|
||||
balance(address: $address, tokenSymbols:["COFE"]){
|
||||
balanceNetwork
|
||||
balanceIncoming
|
||||
balanceOutgoing
|
||||
@ -222,22 +234,24 @@ query {
|
||||
}
|
||||
|
||||
"""
|
||||
# balance_query_result = schema.execute(balance_query)
|
||||
balance_query_result = schema.execute(
|
||||
balance_query, variables={"address": "address_1"})
|
||||
# print(balance_query_result)
|
||||
|
||||
|
||||
transfer_mutation = """
|
||||
mutation {
|
||||
transfer(fromAddress :"0xEb3907eCad74a0013c259D5874AE7f22DcBcC95C",
|
||||
toAddress: "0x82e66cf2766bf20672a605bbf5a6faaa12d5b907"
|
||||
mutation transfer($from: String, $to: String) {
|
||||
transfer(fromAddress : $from,
|
||||
toAddress: $to
|
||||
value: 20
|
||||
tokenSymbol: "GFT" ){
|
||||
|
||||
tokenSymbol: "COFE" ){
|
||||
test
|
||||
}
|
||||
}
|
||||
|
||||
"""
|
||||
transfer_mutation_result = schema.execute(transfer_mutation)
|
||||
transfer_mutation_result = schema.execute(transfer_mutation, variables={
|
||||
"from": address_1, "to": address_2})
|
||||
print(transfer_mutation_result)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user