Chapter 6 - Exposing the Content on AEM Publish for Delivery

Chapter 6 of the AEM Headless tutorial covers ensuring all the necessary packages, configuration and content are on AEM Publish to allow consumption by the Mobile App.

Publishing the Content for AEM Content Services

The configuration and content created to drive the Events through AEM Content Services must be published to AEM Publish so the Mobile App can access it.

Because AEM Content Services is built from Configuration (Content Fragment Models, Editable Templates), Assets (Content Fragments, Images), and Pages all of these pieces automatically enjoy AEM’s content management capabilities, including:

  • Workflow for review and processing
  • and activation/deactivation for pushing and pulling content from the AEM Publish’s AEM Content Services end-points
  1. Ensure the WKND Mobile Application Packages, listed in Chapter 1, are installed on AEM Publish using Package Manager.

  2. Publish the WKND Mobile Events API Editable Template

    1. Navigate to AEM > Tools > General > Templates > WKND Mobile
    2. Select the Event API template
    3. Tap Publish in the top action bar
    4. Publish the template and all references (content policies, content policy mappings, and templates)
  3. Publish the WKND Mobile Events content fragments.

    Note that this is required as the Events API uses the Content Fragment List component, which does not specifically reference Content Fragments.

    1. Navigate to AEM > Assets > Files > WKND Mobile > English > Events
    2. Select all the Event content fragments
    3. Tap the Manage Publication in the top action bar
    4. Leaving the default Publish action as-is, tap Next in the top action bar
    5. Select all content fragments
    6. Tap Publish in the top action bar
      • The Events Content Fragment Model and references Event Images will automatically be published along with the content fragments.
  4. Publish the Events API page.

    1. Navigate to AEM > Sites > WKND Mobile > English > API
    2. Select the Events page
    3. Tap the Manage Publication in the top action bar
    4. Leaving the default Publish action as-is, tap Next in the top action bar
    5. Select the Events page
    6. Tap Publish in the top action bar

Verify AEM Publish

  1. In a new Web browser, ensure you are logged out of AEM Publish and request the following URLs (substituting http://localhost:4503 for whatever host:port AEM Publish is running on).

    These requests should return the same JSON response as when the corresponding AEM Author end-points were reviewed. If they do not, ensure all publications succeeded (check the Replication queues), the WKND Mobile ui.apps package is installed on AEM Publish, and review the error.log for AEM Publish.

Next step

There are no extra packages to install. Ensure that the content and configuration outlined in this section is published to AEM Publish, else subsequent chapters will not work.

recommendation-more-help
e25b6834-e87f-4ff3-ba56-4cd16cdfdec4