Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cardano-client-lib 0.1.5 ADA transfer successful, token transfer failed #6

Open
AdelaDella opened this issue Aug 23, 2023 · 0 comments

Comments

@AdelaDella
Copy link

PaymentTransaction paymentTransaction =
PaymentTransaction.builder()
.sender(senderAccount)
.receiver(receiverAddress)
.amount(amount)
//.unit(CardanoConstants.LOVELACE)
.unit("d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143414458")
.build();

There is no problem transferring ADA main currency.
Transfer d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143414458 Token error reported

[PaymentTransaction(unit=d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143414458, amount=10000)]
22:37:33.090 [main] DEBUG com.bloxbean.cardano.client.backend.api.helper.TransactionHelperService - {
"body" : {
"inputs" : [ {
"transactionId" : "748326fa5b919c485ddbc93c94f0d9a000e4cbcd52d80dc44f71a38b551b2790",
"index" : 1
} ],
"outputs" : [ {
"address" : "addr1qx55fc4tgaeq20wgpm50a49e223cuvu2xl6zchtn8cqj5s69qe0w49serzs4j8xhxmma2c2mkcchcdcj0hkrf22p55ls6nmp33",
"value" : {
"coin" : 168090,
"multiAssets" : [ {
"policyId" : "d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143",
"assets" : [ {
"name" : "0x414458",
"value" : 10000
} ]
} ]
}
}, {
"address" : "addr1q9d03mv8ty0apfxl3w93avamqafgmgnkjn59nd2djjvngmv96j2mprflqpw20jknesga2q6hnhgz6gyaarafjat56e5qwmh2y2",
"value" : {
"coin" : 2413032,
"multiAssets" : [ {
"policyId" : "d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143",
"assets" : [ {
"name" : "0x414458",
"value" : 980000
} ]
} ]
}
} ],
"fee" : 170000,
"ttl" : 101149747,
"mint" : null,
"metadataHash" : null,
"validityStartInterval" : 0
},
"witnessSet" : null,
"metadata" : null
}
22:37:33.097 [main] DEBUG com.bloxbean.cardano.client.backend.api.helper.TransactionHelperService - Requests:
[PaymentTransaction(unit=d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143414458, amount=10000)]
22:37:46.997 [main] DEBUG com.bloxbean.cardano.client.backend.api.helper.TransactionHelperService - {
"body" : {
"inputs" : [ {
"transactionId" : "748326fa5b919c485ddbc93c94f0d9a000e4cbcd52d80dc44f71a38b551b2790",
"index" : 1
} ],
"outputs" : [ {
"address" : "addr1qx55fc4tgaeq20wgpm50a49e223cuvu2xl6zchtn8cqj5s69qe0w49serzs4j8xhxmma2c2mkcchcdcj0hkrf22p55ls6nmp33",
"value" : {
"coin" : 168090,
"multiAssets" : [ {
"policyId" : "d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143",
"assets" : [ {
"name" : "0x414458",
"value" : 10000
} ]
} ]
}
}, {
"address" : "addr1q9d03mv8ty0apfxl3w93avamqafgmgnkjn59nd2djjvngmv96j2mprflqpw20jknesga2q6hnhgz6gyaarafjat56e5qwmh2y2",
"value" : {
"coin" : 2411327,
"multiAssets" : [ {
"policyId" : "d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143",
"assets" : [ {
"name" : "0x414458",
"value" : 980000
} ]
} ]
}
} ],
"fee" : 171705,
"ttl" : 101149747,
"mint" : null,
"metadataHash" : null,
"validityStartInterval" : 0
},
"witnessSet" : null,
"metadata" : null
}
22:37:48.185 [main] ERROR com.bloxbean.cardano.client.backend.api.helper.TransactionHelperService - Trasaction submission failed
Transaction Failed: Result{successful=false, response='{"error":"Bad Request","message":""transaction submit error ShelleyTxValidationError ShelleyBasedEraBabbage (ApplyTxError [UtxowFailure (UtxoFailure (BabbageOutputTooSmallUTxO [((Addr Mainnet (KeyHashObj (KeyHash "a944e2ab4772053dc80ee8fed4b952a38e338a37f42c5d733e012a43")) (StakeRefBase (KeyHashObj (KeyHash "45065eea961918a1591cd736f7d5615bb6317c37127dec34a941a53f"))),Value 168090 (fromList [(PolicyID {policyID = ScriptHash "d2175511c5793b09d27b7ddac0f64cc1b9900fe1dca1607ea949f143"},fromList [(414458,10000)])]),NoDatum,SNothing),Coin 1142150)]))])"","status_code":400}', code=400, value=TransactionResult(signedTxn=[], transactionId=null)}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant