Skip to main content
Version: 0.9.1

Read an Account

import (
"context"
"github.com/trilitech/tzpro-go/tzpro"
"github.com/trilitech/tzgo/tezos"
)

// use default Mainnet client
client := tzpro.DefaultClient
ctx := context.Background()
addr := tezos.MustParseAddress("tz3RDC3Jdn4j15J7bBHZd29EUee9gVB1CxD9")

// get account data and embed metadata if available
params := tzpro.NewAccountParams().WithMeta()
a, err := client.GetAccount(ctx, addr, params)