NodePing.Contacts.update_contact-exclamation-mark

You're seeing just the function update_contact-exclamation-mark, go back to NodePing.Contacts module for more information.
Link to this function

update_contact!(token, id, args, customerid \\ nil)

View Source

Update an existing contact for your account or subaccount.

NOTE When updating a contact's addresses, you must provide the current list of addresses. Any missing addresses will be removed.

You can reference the fields by using the NodePing.Contacts.Contact struct

View the documentation to see the structure for creating contacts: https://nodeping.com/docs-api-contacts.html#post-put

Parameters

  • token - NodePing API token that was provided with account
  • id - The contact id
  • args - Arguments for creating a NodePing contact
  • customerid - optional ID to access a subaccount

Examples

iex> existing_contacts =
     %{
       "A775GC26" => %{
         address: "me@example.com",
         supressup: true,
         type: "email"
       }
     }
iex> updated = NodePing.Contacts.update_contact!(token, id, %{addresses: updated_contact})