code: public static TwilioRestClient getRestClient() {
          if (Twilio.restClient == null) {
              if (Twilio.username == null || Twilio.password == null) {
                  throw new AuthenticationException(
                      "TwilioRestClient was used before AccountSid and AuthToken were set, please call Twilio.init()"
                  );
              }
  
              TwilioRestClient.Builder builder = new TwilioRestClient.Builder(Twilio.username, Twilio.password);
              if (Twilio.accountSid != null) {
                  builder.accountSid(Twilio.accountSid);
              }
              Twilio.restClient = builder.build();
          }
  
          return Twilio.restClient;
      }
docs: Returns (and initializes if not initialized) the Twilio Rest Client.
  
  @return the TWilio Rest Client
  @throws AuthenticationException if initialization required and either accountSid or authToken is null