Save data from an API call to server cache

We don’t own the software. we use the software (we renew every year) but regardless. i was more interested in help based on limited information I provided. assuming the data provided is received via API using PHP how would I store this data in local cache. Can anyone help with that?