Bitcoin
Bitcoin
Bitcoin
الخطة المجانية تغطي المشاريع الشخصية. الدفع حسب الاستخدام يتوسع دون بطاقة.
createrawtransaction assembles an unsigned Bitcoin transaction from a list of UTXO inputs and a set of outputs, returning the serialized result as a hex string. Because Bitcoin uses the UTXO model rather than accounts, you reference the exact txid and vout you intend to spend, and you specify each output as an address paying an amount of BTC. The call is pure construction: it does not select coins, fund the transaction, sign it, or touch the network. Send the request to the Bitcoin JSON-RPC endpoint at https://bitcoin.therpc.io/YOUR_API_KEY, then sign the returned hex elsewhere — typically in an offline wallet — before broadcasting.
{ "data": "<hex>" } entry to the outputs, which Core encodes as a provably-unspendable OP_RETURN output.replaceable as true, so the signed result can later be fee-bumped and rebroadcast.| # | الاسم | النوع | مطلوب | الوصف |
|---|---|---|---|---|
| 1 | inputs | array | نعم | Inputs as { txid, vout, sequence? } objects. |
| 2 | outputs | array | object | نعم | Outputs as address→amount entries and/or { data: hex } for OP_RETURN. |
| 3 | locktime | number | لا | nLockTime for the transaction. |
| 4 | replaceable | boolean | لا | Mark inputs as BIP125 replaceable (opt-in RBF). |
| النوع | الوصف |
|---|---|
| string | The unsigned raw transaction in hex. |
| الكود | الرسالة | السبب |
|---|---|---|
-8 | Invalid parameter | A parameter is out of range or the wrong shape — check verbosity levels, conf_target bounds, and required fields. |
-3 | Type error | An input or output field has the wrong type — check amounts are numbers and txids are strings. |
0.001 means 0.001 BTC (100,000 sat). A wrong unit produces a valid-looking but incorrect transaction with no error.