7 "github.com/docker/docker/api/types/image"
8 "golang.org/x/net/context"
11 // ImageHistory returns the changes in an image in history format.
12 func (cli *Client) ImageHistory(ctx context.Context, imageID string) ([]image.HistoryResponseItem, error) {
13 var history []image.HistoryResponseItem
14 serverResp, err := cli.get(ctx, "/images/"+imageID+"/history", url.Values{}, nil)
19 err = json.NewDecoder(serverResp.body).Decode(&history)
20 ensureReaderClosed(serverResp)