Class OrderContact

java.lang.Object
com.eqixiac.equinix.customerportal.model.json.creators.OrderContact

public class OrderContact extends Object
A contact on a colocation v2 order (cross-connect, shipment, work visit) or a v2 trouble ticket / support case. The contacts array entries are modelled by the spec as an anyOf of two variants:
  • Registered user (ContactRequestRegisteredUser): registeredUsers[] + type (NOTIFICATION, TECHNICAL, or ORDERING on support cases), with optional availability and timezone.
  • Non-registered contact (ContactRequestNonRegisteredUser): firstName, lastName, type (TECHNICAL), details[] of {type, value} (where type is PHONE, MOBILE or EMAIL), with optional availability and timezone.

Use registered(String, java.util.List) / registered(String, java.util.List, String, String) for the first variant and nonRegistered(String, String, java.util.List) / nonRegistered(String, String, java.util.List, String, String) for the second. Only the fields relevant to the chosen variant are serialized.

  • Method Details

    • registered

      public static OrderContact registered(String type, List<String> registeredUsers)
      Builds a registered-user contact (ContactRequestRegisteredUser).
      Parameters:
      type - the contact type (e.g. NOTIFICATION, TECHNICAL)
      registeredUsers - the registered customer-portal user names
      Returns:
      the contact
    • registered

      public static OrderContact registered(String type, List<String> registeredUsers, String availability, String timezone)
      Builds a registered-user contact (ContactRequestRegisteredUser) with availability and timezone.
      Parameters:
      type - the contact type (e.g. NOTIFICATION, TECHNICAL)
      registeredUsers - the registered customer-portal user names
      availability - the contact's availability (WORK_HOURS or ANYTIME)
      timezone - the contact's timezone
      Returns:
      the contact
    • nonRegistered

      public static OrderContact nonRegistered(String firstName, String lastName, List<OrderContact.ContactDetail> details)
      Builds a non-registered contact (ContactRequestNonRegisteredUser).
      Parameters:
      firstName - the contact's first name
      lastName - the contact's last name
      details - the contact details ({type, value} entries; email is required)
      Returns:
      the contact
    • nonRegistered

      public static OrderContact nonRegistered(String firstName, String lastName, List<OrderContact.ContactDetail> details, String availability, String timezone)
      Builds a non-registered contact (ContactRequestNonRegisteredUser) with availability and timezone.
      Parameters:
      firstName - the contact's first name
      lastName - the contact's last name
      details - the contact details ({type, value} entries; email is required)
      availability - the contact's availability (WORK_HOURS or ANYTIME)
      timezone - the contact's timezone
      Returns:
      the contact