(ctx context.Context, email string)
| 10 | ) |
| 11 | |
| 12 | func NewSearchConsole(ctx context.Context, email string) (*searchconsoleapi.Service, error) { |
| 13 | if opts, err := optionsForAccount(ctx, googleauth.ServiceSearchConsole, email); err != nil { |
| 14 | return nil, fmt.Errorf("searchconsole options: %w", err) |
| 15 | } else if svc, err := searchconsoleapi.NewService(ctx, opts...); err != nil { |
| 16 | return nil, fmt.Errorf("create searchconsole service: %w", err) |
| 17 | } else { |
| 18 | return svc, nil |
| 19 | } |
| 20 | } |