Once again, depends on your state. What's good for "A", may not apply to "B"...
From the web:
Creation and perfection
Under the statutes, the lien is usually created by the performance of labor or the supplying of material that improves the property. Just what type of contribution counts as a valid basis for a mechanics lien varies, depending on the particular state statute that applies. Some common examples are:
Laborers, carpenters, electricians, mechanical/HVAC contractors and plumbers working on the project site;
Lumber yards, plumbing supply houses and electrical suppliers;
Architects and civil engineers who drew up the construction plans and specifications; and
Offsite fabricators of specialty items that are ultimately incorporated into the project.
Often, there is no simple dividing line that is useful in every state, or even in every case, for determining this eligibility. Deciding whether a party has a legitimate lien right may depend on examining court cases that have either upheld or rejected lien claims in the same state.
Unlike other security interests, in most states, mechanic's liens are given to contractors and material suppliers who may or may not have a direct contractual agreement with the owner of the land. In fact, this is often the norm because in most cases, the owner of the land contracts only with a general contractor (often called a "prime contractor"). The general contractor, in turn, hires subcontractors ("subs") and material suppliers ("suppliers") to perform the work. These subs and suppliers are entitled to liens on the owner's property to secure their payment from the general contractor.
However, to have an enforceable lien, it usually must be "perfected." This means that the holder of the lien must comply with the statutory requirements for maintaining and enforcing the lien. These requirements, which contain time limits, are generally as follows:
Providing the required preliminary notice to the property owner disclosing the entitlement to the lien (some states).
Filing notices of commencement of work (some states).
Filing notices in the required public records offices of the intention to file a lien if unpaid (some states).
Filing the notice or claim of lien in the required public records offices within a specified period of time after the materials have been supplied or the work completed (all states). The law varies from state-to-state on both the triggering event and the timing of this. Some states require the filing within a period measured from the time when the claimant completes its work, while others specify the event as being after all work on the project has been completed. The filing time periods after the triggering event vary, with 4-6 months being common.
Filing a lawsuit to foreclose the lien within a specified time period.