SAP

Manage my Account SAP Devs YouTube ↗ Learnings ↗ Community ↗ Provide Feedback ↗
Logout
⤢ Open full site

Build an Augmented Reality Experience app with FioriAR

Using modern technologies becomes more and more crucial for the success of native business apps as the requirements of professional users are more extensive. Utilizing Augmented Reality on powerful mobile devices in order to bring more value to business apps was never so easy. The SAP BTP SDK for iOS Development Team released a whole set of open-source projects for your consumption, one of these is the `FioriAR` package helping you to quickly build AR experiences using the newest version of `ARKit` by Apple. In this tutorial you will learn how to leverage the `FioriAR` Swift package to build you first AR experience in no time, you will use the provided APIs and SwiftUI Views to enable users to create their own AR Scenes and publish them to SAP Mobile Services in order to be managed there.

Overview

You will learn

  • ✔How to add the FioriAR Swift package to your Xcode project using the Swift Package Manager
  • ✔How to use the FioriAR APIs and SwiftUI screens to build an AR Scene Authoring View and AR Scene Display View This tutorial is based on SwiftUI and will only reference to the use of FioriAR within a UIKit based app, hence the above mentioned prerequisites of setting up the SAP BTP SDK for iOS and downloading the SAP BTP SDK for iOS Assistant is optional. You can install the SDK and the assistant if you want to implement the app with UIKit. The project can be found in the SAP Samples on GitHub: Mobile Augmented Reality GitHub
Kevin Muessig K Kevin Muessig August 21, 2026
Created on January 9, 2023
Contributors

More from Kevin Muessig

See all 13 tutorials by Kevin Muessig →

Prerequisites

  • Development environment: Apple Mac running macOS Catalina or higher with Xcode 13 or higher
  • Device: You need an iPad or iPhone in order to run and test the app
  • Knowledge: You should have a basic understanding of the Swift programming language and iOS Development with Xcode.
  • Tutorial: Access SAP Mobile Services
  • Optional: Group: Set Up the SAP BTP SDK for iOS
  • Optional: SAP BTP SDK for iOS: Version 7.0 or higher

Steps

Details

You will learn

  • How to add the FioriAR Swift package to your Xcode project using the Swift Package Manager
  • How to use the FioriAR APIs and SwiftUI screens to build an AR Scene Authoring View and AR Scene Display View

This tutorial is based on SwiftUI and will only reference to the use of FioriAR within a UIKit based app, hence the above mentioned prerequisites of setting up the SAP BTP SDK for iOS and downloading the SAP BTP SDK for iOS Assistant is optional. You can install the SDK and the assistant if you want to implement the app with UIKit.

The project can be found in the SAP Samples on GitHub: Mobile Augmented Reality GitHub


Step 1 Create a New SwiftUI Xcode Project
—

Before you start following the first step, notice that if you want to go the UIKit based approach, go and follow the Set Up the SAP BTP SDK for iOS tutorials in order to generate an app using the SAP BTP SDK for iOS Assistant. The first step is solely for the SwiftUI based approach!

In this step you will use the Xcode Project creation flow to create a SwiftUI based app project.

  1. Open up your instance of Xcode, here using Xcode Version 13.2.1 (13C100).

    !

    New SwiftUI Xcode Project
    New SwiftUI Xcode Project

  2. Create a new App project.

    !

    New SwiftUI Xcode Project
    New SwiftUI Xcode Project

  3. Give the app project a name and make sure you’ve selected SwiftUI as the Interface. You can choose the name freely.

    !

    New SwiftUI Xcode Project
    New SwiftUI Xcode Project

  4. Create the project in a directory of your choice.

    !

    New SwiftUI Xcode Project
    New SwiftUI Xcode Project

  5. After you’ve created the project you should see the project opening up.

    !

    New SwiftUI Xcode Project
    New SwiftUI Xcode Project

Step 2 Add the FioriAR Swift Package to the Project
+
Step 3 Implement the Needed Data Models
+
Step 4 Implement the ARScene Model
+
Step 5 Add the Provided Util Files
+
Step 6 Create a Mobile App Configuration
+
Step 7 Add the Authentication Parameters to the Project
+
Step 8 Create a View for Displaying the SceneAuthoringView
+
Step 9 Make the SAPURLSession available throughout the app
+
Step 10 Add Navigation to the ARSceneAuthoringContentView
+
Step 11 Inspect Created Augmented Reality Scenes on SAP Mobile Services
+
Step 12 Implement the ARSceneListContentView
+
Step 13 Implement the ARSceneContentView
+
Step 14 Add the ARSceneListContentView to the Navigation Flow
+
Step 15 Display a created AR Scene
+
Step 16 Add Additional Code in Order to View local Reality Files
+

Resources

Discussion

Share feedback on this tutorial or join the conversation in SAP Community.

Submit detailed feedback Discuss in Community
Steps
Step 1 of 16
1. Create a New SwiftUI Xcode Project 2. Add the FioriAR Swift Package to the Project 3. Implement the Needed Data Models 4. Implement the ARScene Model 5. Add the Provided Util Files 6. Create a Mobile App Configuration 7. Add the Authentication Parameters to the Project 8. Create a View for Displaying the SceneAuthoringView 9. Make the SAPURLSession available throughout the app 10. Add Navigation to the ARSceneAuthoringContentView 11. Inspect Created Augmented Reality Scenes on SAP Mobile Services 12. Implement the ARSceneListContentView 13. Implement the ARSceneContentView 14. Add the ARSceneListContentView to the Navigation Flow 15. Display a created AR Scene 16. Add Additional Code in Order to View local Reality Files