WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am consuming an API that gives me a list of people and their profiles. My initial idea was working perfectly fine when it's just the list of people because I was just saving the ids and names using transients and then displaying them on a page. However, I now need to display each person's profile on a page so I reconstructed my idea.

My flow is now like this:


Store in cache (transient)

Insert in post (custom post type) - my reason for inserting to the DB is because I need to have a format like /people/person_id. /people has the list of people /people/person_id has a person's profile.

The API consumer just runs once a day.

Is this a good process?

share|improve this question
That's the way I'd do it. – vancoder May 2 '14 at 18:43
Hey @vancoder thanks for answering. I'm wondering if there's another way to display people/person_id without inserting to DB and just use transients all the way. – Pi Lover May 2 '14 at 18:59
if you need an index (/people) and a single (/people/person_id) that looks like a CPT to me. – vancoder May 2 '14 at 22:27

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.