The getNFCPeer() method of the MozNFC interface returns a Peer to Peer DOM object (MozNFCPeer) that can be used to transfer data to another NFC-enabled device.
The mozNfc property returns a MozNFC object that can be used to access Firefox OS's NFC functionality: Near Field Communication (NFC) is a short range radio technology used to exchange data and tags between mobile devices by tapping them together or moving them close to each other.
The id property of the MozNDEFRecord interface is application dependent (an appropriate id can be used, depending on functionality), but generally will return an NDEF Record identifier.
The payload property of the MozNDEFRecord interface is application dependent (for example, a contacts application could contain URLs, mime-types, postal address, etc., to emulate vCards).
The onpeerlost event handler of the MozNFC interface handles the peerlost event, which is fired when the MozNFCPeer object received in MozNFC.onpeerready is no longer available or not in proximinty (e.g. the peer device moves out of range.).
The onpeerready event handler of the MozNFC interface handles the peerready event, which fires when a suitable peer (an NFC-enabled device) comes into range of the device your NFC application is running on.