# Amount(in: USD) for Bitcoin coinpath Query Incorrect?

**URL:** https://community.bitquery.io/t/amount-in-usd-for-bitcoin-coinpath-query-incorrect/2028
**Category:** GraphQL API
**Created:** [August 10, 2024, 1:23am UTC](https://community.bitquery.io/t/amount-in-usd-for-bitcoin-coinpath-query-incorrect/2028 "2024-08-10T01:23:17Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![donnfelker](https://sea2.discourse-cdn.com/flex016/user_avatar/community.bitquery.io/donnfelker/32/926_2.png) [@donnfelker](https://community.bitquery.io/u/donnfelker)
#### Post date: [August 10, 2024, 1:23am UTC](https://community.bitquery.io/t/amount-in-usd-for-bitcoin-coinpath-query-incorrect/2028/1 "2024-08-10T01:23:17Z")

</div>

When I run the following coinpath query to find a transaction between two bitcoin addresses I get the amount back from the API `20.015336124375`, which is from a single txHash of `4b56824b351880033d27d7575a4d1ef8afb6086489b58772445a663f62ccbf18`. If I [look up this transaction on blockchain.info](https://www.blockchain.com/explorer/transactions/btc/4b56824b351880033d27d7575a4d1ef8afb6086489b58772445a663f62ccbf18), and find the destination address, I see the USD value is `25.86`.

How is bitquery calculating this value? I’m wondering why its different because I need this value to be as accurate as possible.

Here’s the query:

```auto
{
  bitcoin(network: bitcoin) {
    outboundTransactions: coinpath(
      initialAddress: {is: "bc1qlp98thyws2t7am7r292d8yy0j7v7lymf2m93ry"}
      receiver: {is: "1DfUUm4zUv7yWt7rWzZuweNvSPogTsGcjx"}
      depth: {lteq: 1}
      options: {direction: outbound}
      initialDate: {between: ["2010-01-01T00:00:00Z", "2023-12-31T23:59:59Z"]}
    ) {
      sender {
        address
      }
      receiver {
        address
      }
      amount(in: USD)
      currency {
        name
        symbol
      }
      transactions {
        amount
        height
        timestamp
        txHash
        txValue
      }
    }
  }
}

```

---

<div class="post-metadata">

### Author: ![Divya](https://avatars.discourse-cdn.com/v4/letter/d/13edae/32.png) [@Divya](https://community.bitquery.io/u/Divya)
#### Post date: [August 12, 2024, 7:23am UTC](https://community.bitquery.io/t/amount-in-usd-for-bitcoin-coinpath-query-incorrect/2028/2 "2024-08-12T07:23:14Z")

</div>

> [@donnfelker](#):
>
> When I run the following coinpath query to find a transaction between two bitcoin addresses I get the amount back from the API `20.015336124375`, which is from a single txHash of `4b56824b351880033d27d7575a4d1ef8afb6086489b58772445a663f62ccbf18`. If I [look up this transaction on blockchain.info](https://www.blockchain.com/explorer/transactions/btc/4b56824b351880033d27d7575a4d1ef8afb6086489b58772445a663f62ccbf18), and find the destination address, I see the USD value is `25.86`.
> 
> How is bitquery calculating this value? I’m wondering why its different because I need this value to be as accurate as possible.

To get the exact input, and output value for that particular tx

use these fields

```auto
 transaction {
        hash
        valueIn
        valueOut
      }

```

 ![image](https://us1.discourse-cdn.com/flex016/uploads/bitquery/original/1X/5b3cd4447dd423b5f69cf353da5198a84135490d.png)

---

<div class="post-metadata">

### Author: ![donnfelker](https://sea2.discourse-cdn.com/flex016/user_avatar/community.bitquery.io/donnfelker/32/926_2.png) [@donnfelker](https://community.bitquery.io/u/donnfelker)
#### Post date: [August 13, 2024, 10:44am UTC](https://community.bitquery.io/t/amount-in-usd-for-bitcoin-coinpath-query-incorrect/2028/3 "2024-08-13T10:44:58Z")

</div>

Where does that go in the query? Is that a different query?

---

<div class="post-metadata">

### Author: ![Divya](https://avatars.discourse-cdn.com/v4/letter/d/13edae/32.png) [@Divya](https://community.bitquery.io/u/Divya)
#### Post date: [August 13, 2024, 4:22pm UTC](https://community.bitquery.io/t/amount-in-usd-for-bitcoin-coinpath-query-incorrect/2028/4 "2024-08-13T16:22:15Z")

</div>

Apologies. Same query, add those fields

```auto
{
  bitcoin(network: bitcoin) {
    outboundTransactions: coinpath(
      initialAddress: {is: "bc1qlp98thyws2t7am7r292d8yy0j7v7lymf2m93ry"}
      receiver: {is: "1DfUUm4zUv7yWt7rWzZuweNvSPogTsGcjx"}
      depth: {lteq: 1}
      options: {direction: outbound}
      initialDate: {between: ["2010-01-01T00:00:00Z", "2023-12-31T23:59:59Z"]}
    ) {
      sender {
        address
      }
      receiver {
        address
      }
      amount(in: USD)
      currency {
        name
        symbol
      }
      transactions {
        amount
        height
        timestamp
        txHash
        txValue
      }
      transaction {
        hash
        valueIn
        valueOut
      }
    }
  }
}

```
