do you really need to have the content in a file? Maybe the global variable is enough ? You can access it from other scripts but you cannot access it by FTP..
If you need to report some values to another device (central logger) you can configure log system to send some events to remote Ssyslog sever and ‘export’ the values from script thtough the log system (:log info “blabbla”)