Sign a transaction from a specific developer-controlled wallet.
NOTE: This endpoint is only available for the following chains: SOL
, SOL-DEVNET
, NEAR
, NEAR-TESTNET
, EVM
, EVM-TESTNET
. Each chain defines its own standard, please refer to Signing APIs doc.
System-generated unique identifier of the resource.
Raw transaction string that needs to be signed. Excluded with transaction
. Required without transaction
.
Required to be base64 encoded for NEAR, Solana chains. Required to be hex encoded for EVM chains.
Transaction object in JSON that needs to be signed. Excluded with rawTransaction
. Required without rawTransaction
.
NOTE: This field is only supported by EVM
chains.
The human readable explanation for this sign action. Useful for presenting with extra information.
A base64 string expression of the entity secret ciphertext. The entity secret should be encrypted by the entity public key. Circle mandates that the entity secret ciphertext is unique for each API request.
1from circle.web3 import developer_controlled_wallets
2from circle.web3 import utils
3
4client = utils.init_developer_controlled_wallets_client(api_key=key, entity_secret=entitySecret)
5
6api_instance = developer_controlled_wallets.SigningApi(client)
7request = developer_controlled_wallets.SignTransactionRequest.from_dict({
8 "walletId": "301e9038-e4c3-5a77-a9fe-95fd644f4c85",
9 "rawTransaction": "0x02f283aa36a780830f4240841571d6868252089467df4bc369de8686e0fa53f7e1c3c6fd371ae13c8609184e72a00080c0808080",
10 "memo": "test",
11})
12response = api_instance.sign_transaction(sign_transaction_request=request)
13print(response.json())
14
1{
2 "data": {
3 "signature": "3W6r38STvZuBSmk2bbbct132SjEsYSARo3CJi3JQvNUaFoYu...",
4 "signed_transaction": "AgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABpzlAhqqen7eyTe0KQ3w+9NS4E+7sscb+Cr...",
5 "tx_hash": "0x4a25cc5e661d8504b59c5f38ba93f010e8518966f00e2ceda7955c4b8621357d"
6 }
7}