This is (probably, I've never looked at what FlexQuery reports) IBKR adding 
the transaction costs to the cost basis (which is how US tax accounting 
works). So when you buy something it will have a (very slightly) higher 
cost basis than whatever the order execution said.

On Saturday, April 13, 2024 at 3:30:58 PM UTC+7 [email protected] wrote:

> Hi everyone
> I recently closed some positions I held at InteractiveBrokers, for which i 
> have a nice API-based ingestion pipeline to beancount. However I noted lots 
> of "No position matches"-Errors. 
> Turns out, the reported cost basis / Trade prices  of the closed positions 
> are very slightly off (by a handful of USD-cents) the reported cost basis 
> at purchase. As a result, beancount can't match the lots. 
>
>
>    1. Has anyone dealt with this specific issue with IBKR before?
>    2. What would be your best practice?
>       1. change the cost basis reported at opening time to match the cost 
>       basis at closing time?
>       2. change the cost basis reported at closing time to match the cost 
>       basis at opening time?
>       3. ...?
>    
> Below a sample pair of transactions, as i obtain them via the FlexQuery 
> API.note the $172.74 vs. $172.86
> Thanks for any hints!
> nugget
>
> 2022-04-08 * "VBR" "BUY 3 VBR @ 172.74 USD"
>   Assets:Invest:IB:VBR             3 VBR {172.74 USD, 2022-04-08}
>   Assets:Invest:IB:USD       -518.22 USD
> ...
> 2024-03-04 * "VBR" "SELL -3 VBR @ 183.81 USD"
>   Assets:Invest:IB:VBR               -3 VBR {172.86 USD, 2022-04-08} @ 
> 183.81 USD
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/6d6ac093-3052-45e2-a24b-6ee04ad773b1n%40googlegroups.com.

Reply via email to