Here is a link to Particle reference material about EEPROM emulation. These functions, I think, you are interested in:
EEPROM.put()
EEPROM.get()
and more described:
https://docs.particle.io/reference/device-os/firmware/#eeprom
It would help to create a "struct" for persistent data you want to store/retrieve and assign an address to it. This thread nicely covers this as well as assigning a data version number which comes in very handy:
https://community.particle.io/t/eeprom-technique/29263