Whenever the division shall be of the opinion that a public utility, subject to its supervision, is failing or omitting, or about to fail or omit, to do anything required of it by law or by order of the division, or is doing anything, is about to do anything, or is permitting anything, or is about to permit anything to be done contrary to or in violation of law or of any order of the division, it shall direct the attorney general to commence an action or proceeding in the supreme court in the name of the division for the purpose of having the violations or threatened violations prevented. The attorney general shall thereupon begin the action or proceeding by petition to the supreme court, alleging the violation or threatened violation complained of, and praying for appropriate relief. It shall thereupon be the duty of the court to specify a time not exceeding twenty (20) days after the service of the copy of the petition, within which the public utility complained of must answer the petition, and in the meantime the public utility may be restrained. In the case of a default in answering, or after the answer, the court shall immediately inquire into the facts and circumstances of the case. Such corporations or persons as the court may deem necessary or proper to be joined as parties in order to make its judgment, order, or writ effective, may be joined as parties. The final judgment in any action or proceeding, shall either dismiss the action or proceeding or direct that appropriate relief be granted as prayed for in the petition, or in modified or other form.
R.I. Gen. Laws § 39-4-23