Tipalti.API.Payee.update_or_create_payee_info
You're seeing just the function
update_or_create_payee_info
, go back to Tipalti.API.Payee module for more information.
Specs
update_or_create_payee_info(Tipalti.idap(), map(), keyword()) :: :ok | {:error, Tipalti.ClientError.t()} | {:error, Tipalti.RequestError.t()}
Updates a payee's basic info.
If the payee does not exist, it will be created. The details must match the ones in the payee bank records. State can either be null, or a valid 2 letter US state. If skip_nulls=true the parameters with null values will be ignored. If skip_nulls=false the null values will overwrite existing values. Country is a 2 letter ISO 3166 code.
Possible fields:
- first_name - string
- last_name - string
- street1 - string
- street2 - string
- city - string
- state - string
- zip - string
- country - string
- email - string
- company - string
- alias - string
- preferred_payer_entity - string
- ap_account_number - string
- payment_terms_id - string
Required options:
- skip_nulls - boolean
- override_payable_country - boolean
Examples
iex> update_or_create_payee_info("newpayee", %{first_name: "John", last_name: "Smith"}, skip_nulls: true, override_payable_country: false)
:ok
iex> update_or_create_payee_info("invalidname", %{first_name: "José", last_name: "Valim"}, skip_nulls: true, override_payable_country: false)
{:error, %Tipalti.ClientError{error_code: "ParameterError", error_message: "Invalid payee first name"}}
iex> update_or_create_payee_info("newpayee", %{first_name: "John", last_name: "Smith"}, [])
{:error, {:missing_required_option, :skip_nulls}}