Skip to content

coinbase: scrape transaction history #29

@dckc

Description

@dckc

I downloaded a "complete" transaction report, but the transactions don't add up to the balance. It seems to be missing "transfers".

But I seem to be able to compute the balance using a DOM query:

acs = document.querySelectorAll('*[data-element="AmountContainer"]')
acs.length // 245
ns = [...acs].map(ac => Number(ac.textContent.split(' ')[0].replace('−', '-').replace('+', '').replace(',', '')))
sum = ns => ns.reduce((acc, x) => acc + x, 0)
sum(ns)

To get associated transaction info, I'm starting with...

tis = document.querySelectorAll('*[data-component="TransactionItem"]')

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions