code: public GetInstancesHealthStatusRequest withInstances(String... instances) {
          if (this.instances == null) {
              setInstances(new java.util.ArrayList<String>(instances.length));
          }
          for (String ele : instances) {
              this.instances.add(ele);
          }
          return this;
      }
docs: <p>
  An array that contains the IDs of all the instances that you want to get the health status for.
  </p>
  <p>
  If you omit <code>Instances</code>, AWS Cloud Map returns the health status for all the instances that are
  associated with the specified service.
  </p>
  <note>
  <p>
  To get the IDs for the instances that you've registered by using a specified service, submit a
  <a>ListInstances</a> request.
  </p>
  </note>
  <p>
  <b>NOTE:</b> This method appends the values to the existing list (if any). Use
  {@link #setInstances(java.util.Collection)} or {@link #withInstances(java.util.Collection)} if you want to
  override the existing values.
  </p>
  
  @param instances
  An array that contains the IDs of all the instances that you want to get the health status for.</p>
  <p>
  If you omit <code>Instances</code>, AWS Cloud Map returns the health status for all the instances that are
  associated with the specified service.
  </p>
  <note>
  <p>
  To get the IDs for the instances that you've registered by using a specified service, submit a
  <a>ListInstances</a> request.
  </p>
  @return Returns a reference to this object so that method calls can be chained together.