Thanks to the wording of your question, I just found this, and wonder if its the answer - Contract and Commercial Law Act 2017 - https://www.legislation.govt.nz/act/public/2017/0005/21.0/whole.html#DLM6844064, Section 12(2). Section 12 reads:
Deed or contract for benefit of person who is not party to deed or contract
(1) This section applies to a promise contained in a deed or contract that confers, or purports to confer, a benefit on a person, designated by name, description, or reference to a class, who is not a party to the deed or contract.
(2) The promisor is under an obligation, enforceable by the beneficiary, to perform the promise.
(3) This section applies whether or not the person referred to in subsection (1) is in existence when the deed or contract is made.
Deed or contract for benefit of person who is not party to deed or contract
(1) This section applies to a promise contained in a deed or contract that confers, or purports to confer, a benefit on a person, designated by name, description, or reference to a class, who is not a party to the deed or contract.
(2) The promisor is under an obligation, enforceable by the beneficiary, to perform the promise.
(3) This section applies whether or not the person referred to in subsection (1) is in existence when the deed or contract is made.