Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8005545
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T17:15:29+00:00 2026-06-04T17:15:29+00:00

Background: I am working on a web application, that I plan to launch with

  • 0

Background:

I am working on a web application, that I plan to launch with iPhone and Android versions in the near future, and I have some questions about developing an API for use by the different front-ends.

I Started with This:

I was reading this TutsPlus tutorial, which talks about creating an API-centric web application, meaning that all of your browser calls and smartphone app calls are routed through the API.

What especially got me excited, was this statement in the tutorial from Twitter:

One of the most important architectural changes is that Twitter.com is now a client of our own API. It fetches data from the same endpoints that the mobile site, our apps for iPhone, iPad, Android, and every third-party application use.

The above statement reflects, what I would ideally like to create.

Then I Saw This:

I found this TutsPlus tutorial, which talks about, how to build a REST API for CodeIgniter. This was good, because I am developing my application in CodeIgniter, using the Modular Extensions plugin – HMVC, and I thought it would be perfect for my purposes.

The only thing, that I’m somewhat lost in, is the way Phil Sturgeon seems to suggest to create the API. He suggests to have all of your front-end code modules completed and then create an API for each of the modules in their respective directories (not necessarily in that order). This would be fine if I didn’t want it to be API-centric.

And I Want to Know How to Do This:

How should I proceed to get a blend of both tutorials:

  • API-centric application that can be used by a browser application as well as separate mobile applications
  • REST API for CodeIgniter (with HMVC modules)

Should I:

  • Just follow the API-centric tutorial and try to tailor it to my needs?
  • Follow the CodeIgniter-specific tutorial and use Phil Sturgeon’s advice for how to implement it with HVMC?
  • A combination of both?
  • Neither?
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T17:15:31+00:00Added an answer on June 4, 2026 at 5:15 pm

    Take a look at Eating your own Dogfood by Nick Jackson. These are slides from CICONF 2012 where he details how this all works.

    Building your API first is a great idea, then your application can use the API to fetch the data itself. This is of course a little slower as you’re adding a HTTP request on data, but locally its not too bad and if you use HMVC to make the request it’s even quicker.

    In the tutorial I didn’t get into HMVC because it’s an extra subject, but it can be awesome for adding modular API’s. In some simple applications I just make a /api folder like the tutorial suggested but PyroCMS Professional has an API module and a sexy route to allow modular API stuff:

    $route['api/([a-zA-Z0-9_-]+)/(:any)']       = '$1/api/$2';
    $route['api/([a-zA-Z0-9_-]+)']              = '$1/api/index';
    

    This means I can have a “api.php” controller in every module and still use the /api/controller/method syntax or even /api/controller if you have function index_get().

    I would strongly suggest you grab PyroCMS Professional for this feature. Yep you gotta pay, but it handles user key generation, authorisation, logging, etc all out of the box and handles your website too.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm a person with a non-programming background working on a web application that must
I have a class in a web application I am working on that holds
First some background: I'm working on an application and I'm trying to follow MVVM
I'm working on a web application that uses ASP.NET 3.5 and C#. Structurally, I
First some background, I am currently working on a relatively large Asp.Net MVC application
I have a web service that creates a thread to process some data in
I have android code that uses a background process to routinely (e.g. hourly) connect
I am working on a Silverlight application that uses WCF. I need to have
First Some Background I'm planning out the architecture for a new PHP web application
Background I'm developing a research application that runs on Android phones. In short, the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.