> For a complete page index, fetch https://docs.conduit.xyz/llms.txt

# eth_fillTransaction

POST https://rpc.plume.org/YOUR_API_KEY
Content-Type: application/json

Takes a partial transaction and fills in `nonce`, `gas`, fee fields, and `chainId` from the node's current state. Returns both the RLP-encoded unsigned transaction and the filled transaction object. The result is unsigned (`r`, `s`, `v` are zero), so you still need to sign it before sending. Values depend on the sender's current nonce and current fees, so results change over time.

⚡ Compute Units: [75 CU](https://docs.conduit.xyz/rpc-nodes/information/compute-units)

Reference: https://docs.conduit.xyz/rpc-nodes/json-rpc-reference/eth-fill-transaction

## Request

### Body (application/json)

This endpoint expects an object.

- `transaction` (CallObject, required) — Partial transaction. `from` is required to look up the nonce.

## Response

### 200

RLP-encoded unsigned transaction and the filled transaction object.

- `raw` (string, optional)
- `tx` (EthFillTransactionResultTx, optional) — Filled, unsigned transaction. `r`, `s`, and `v` are `0x0` until you sign it; `hash` is the hash of the unsigned payload.

## Types

### CallObject

A transaction call object. All fields are optional. Both `data` and `input` are accepted for backwards compatibility — `input` is the canonical field per the Ethereum execution spec.

- `from` (string, optional) — 20-byte sender address (optional)
- `to` (string, optional) — 20-byte target address (optional for contract creation)
- `gas` (string, optional) — Gas limit as hex-encoded integer (optional)
- `gasPrice` (string, optional) — Legacy gas price in wei as hex-encoded integer (optional)
- `maxFeePerGas` (string, optional) — EIP-1559 max total fee per gas in wei as hex-encoded integer (optional)
- `maxPriorityFeePerGas` (string, optional) — EIP-1559 max miner tip per gas in wei as hex-encoded integer (optional)
- `maxFeePerBlobGas` (string, optional) — EIP-4844 max fee per blob gas in wei as hex-encoded integer (optional)
- `value` (string, optional) — Value in wei as hex-encoded integer (optional)
- `data` (string, optional) — ABI-encoded call data, hex-encoded (optional). Alias for `input`; prefer `input` for new clients.
- `input` (string, optional) — ABI-encoded call data, hex-encoded (optional). Canonical name per Ethereum execution spec; alias of `data`.
- `nonce` (string, optional) — Sender nonce as hex-encoded integer (optional, ignored by `eth_call` but accepted)
- `type` (string, optional) — Transaction type as hex-encoded byte (optional): 0x0 legacy, 0x1 EIP-2930 access list, 0x2 EIP-1559, 0x3 EIP-4844 blob, 0x4 EIP-7702 authorization
- `chainId` (string, optional) — Chain ID as hex-encoded integer (optional)
- `accessList` (list of CallObjectAccessListItems, optional) — EIP-2930 access list (optional). Pre-declaring storage slots the transaction will touch reduces gas cost.
- `blobs` (list of string, optional) — EIP-4844 blob data, raw 128KB blobs as hex-encoded bytes (optional). Typically only used by builder/sequencer code paths.
- `blobVersionedHashes` (list of string, optional) — EIP-4844 versioned hashes of blob commitments (optional). One hash per blob.
- `authorizationList` (list of CallObjectAuthorizationListItems, optional) — EIP-7702 authorization list (optional). Each entry is a signed authorization tuple.

### EthFillTransactionResultTx

Filled, unsigned transaction. `r`, `s`, and `v` are `0x0` until you sign it; `hash` is the hash of the unsigned payload.

- `type` (string, optional)
- `chainId` (string, optional)
- `nonce` (string, optional)
- `gas` (string, optional)
- `maxFeePerGas` (string, optional)
- `maxPriorityFeePerGas` (string, optional)
- `gasPrice` (string, optional)
- `to` (string, optional)
- `value` (string, optional)
- `input` (string, optional)
- `accessList` (list of any, optional)
- `r` (string, optional)
- `s` (string, optional)
- `v` (string, optional)
- `yParity` (string, optional)
- `hash` (string, optional)

### CallObjectAccessListItems

- `address` (string, required)
- `storageKeys` (list of string, required)

### CallObjectAuthorizationListItems

- `chainId` (string, required)
- `address` (string, required)
- `nonce` (string, required)
- `yParity` (string, required)
- `r` (string, required)
- `s` (string, required)

## Examples

**Request**

```json
[
  {
    "data": "0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387",
    "from": "0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387",
    "to": "0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2"
  }
]
```

**Response**

```json
{
  "id": "1",
  "jsonrpc": "2.0",
  "result": {
    "raw": "0x02f851830a767982012c830f4240830f4434827316944e742319f6b0fec4afa504fc8ed3ceab0fb751a280a470a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387c0808080",
    "tx": {
      "accessList": [],
      "chainId": "0xa7679",
      "gas": "0x7316",
      "hash": "0xf2c4865d50f31d03d85c08f69b5c2d8add0e4e6e6516b4a38dd2aaba4ada1128",
      "input": "0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387",
      "maxFeePerGas": "0xf4434",
      "maxPriorityFeePerGas": "0xf4240",
      "nonce": "0x12c",
      "r": "0x0",
      "s": "0x0",
      "to": "0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2",
      "type": "0x2",
      "v": "0x0",
      "value": "0x0",
      "yParity": "0x0"
    }
  }
}
```

**SDK Code**

```python
import requests

url = "https://rpc.plume.org/YOUR_API_KEY"

payload = [
    {
        "data": "0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387",
        "from": "0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387",
        "to": "0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2"
    }
]
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://rpc.plume.org/YOUR_API_KEY';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: '[{"data":"0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387","from":"0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387","to":"0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2"}]'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://rpc.plume.org/YOUR_API_KEY"

	payload := strings.NewReader("[\n  {\n    \"data\": \"0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"from\": \"0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"to\": \"0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2\"\n  }\n]")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://rpc.plume.org/YOUR_API_KEY")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "[\n  {\n    \"data\": \"0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"from\": \"0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"to\": \"0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2\"\n  }\n]"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://rpc.plume.org/YOUR_API_KEY")
  .header("Content-Type", "application/json")
  .body("[\n  {\n    \"data\": \"0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"from\": \"0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"to\": \"0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2\"\n  }\n]")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://rpc.plume.org/YOUR_API_KEY', [
  'body' => '[
  {
    "data": "0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387",
    "from": "0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387",
    "to": "0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2"
  }
]',
  'headers' => [
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://rpc.plume.org/YOUR_API_KEY");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "[\n  {\n    \"data\": \"0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"from\": \"0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387\",\n    \"to\": \"0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2\"\n  }\n]", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = ["Content-Type": "application/json"]
let parameters = [
  [
    "data": "0x70a082310000000000000000000000005950baf9a858e3ea17fd6e753d3ac6f3e9152387",
    "from": "0x5950baf9a858e3ea17fd6e753d3ac6f3e9152387",
    "to": "0x4e742319f6b0fec4afa504fc8ed3ceab0fb751a2"
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://rpc.plume.org/YOUR_API_KEY")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```