The negotiations the disclosure of outside legal clients by state lawmakers was a “member-driven” effort, according to Senate Majority Leader Dean Skelos.

Senate Republicans on Sunday night announced an agreement with Gov. Andrew Cuomo to create a system with built-in protections and allowances for client disclosure by state lawmakers who also work as attorneys.

The ethics bill was one of the final hurdles to achieving a budget deal, alongside an agreement on education reform.

Cuomo had initially reached a deal with Assembly Democrats on the ethics package, but Senate Republicans balked at the disclosure push.

In the end, a group of Senate Republicans negotiated the details of the legislation.

A main question remains over whether the extent of disclosure for lawmakers who are attorneys who are “of counsel” at firms and have no direct clients themselves, but help bring business to the firm.

No bill language is available yet, but lawmakers insisted the disclosure would be broad.

“There’s no distinction in the bill between lawyers who work with firms and lawyers who work in small firms dealing with smaller clients,” said Sen. John DeFrancico, one of the negotiators of the bill and an attorney.

Senate Republicans negotiated an agreement with Cuomo that allows for the Office of Court Administration to determine whether a client should or should not be disclosed based on a series of criteria, including whether the client has business before state government, is involved in a divorce proceeding or is a case that involves a child.

“The lawyer would have to submit a statement that the client doesn’t do business with the state, has not received any grants, a whole series of things to try to take care of the thing people are concerned about with our former speaker,” DeFrancisco said.

The agreement comes after the arrest earlier this year of former Speaker Sheldon Silver, who is accused of masking legal referrals as bribes.

The initial ethics deal with the Assembly that includes the $5,000 threshold for business remains in tact, lawmakers said.

The ethics pacakge also includes reforms to the travel per diem disbursement system as well as disclosure of independent expenditures and other campaign finance reform measures.