code: func (api *API) GetInputs(seed Trytes, options GetInputsOptions) (*Inputs, error) {
  	options = getInputDefaultOptions(options)
  	if err := Validate(
  		ValidateSeed(seed), ValidateSecurityLevel(options.Security),
  		ValidateStartEndOptions(options.Start, options.End),
  	); err != nil {
  		return nil, err
  	}
  
  	opts := options.ToGetNewAddressOptions()
  	addresses, err := api.GetNewAddress(seed, opts)
  	if err != nil {
  		return nil, err
  	}
  	balances, err := api.GetBalances(addresses, 100)
  	if err != nil {
  		return nil, err
  	}
  
  	inputs := api.GetInputObjects(addresses, balances.Balances, opts.Index, opts.Security)
  
  	// threshold is an api hard cap for needed inputs to fulfil the threshold value
  	if options.Threshold != nil {
  		threshold := *options.Threshold
  
  		if threshold > inputs.TotalBalance {
  			return nil, ErrInsufficientBalance
  		}
  
  		thresholdInputs := Inputs{}
  		for i := range inputs.Inputs {
  			if thresholdInputs.TotalBalance >= threshold {
  				break
  			}
  			input := inputs.Inputs[i]
  			thresholdInputs.Inputs = append(thresholdInputs.Inputs, input)
  			thresholdInputs.TotalBalance += input.Balance
  		}
  		inputs = thresholdInputs
  	}
  
  	return &inputs, nil
  }
docs: // GetInputs creates and returns an Inputs object by generating addresses and fetching their latest balance.