Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
644528f
chore(example): commit empty SwiftUI SPM sample scaffold
w-goog Apr 17, 2026
1558605
g-orchestrated: add AppDelegate for SwiftUI SPM sample
w-goog Apr 17, 2026
3f1b3e6
g-orchestrated: build SwiftUI view with auth/exchange/userinfo/clear …
w-goog Apr 17, 2026
5e3602f
g-orchestrated: add AuthManager porting Carthage auth flow to Observa…
w-goog Apr 17, 2026
e9543ef
g-orchestrated: add Info.plist registering com.example.app redirect U…
w-goog Apr 17, 2026
7e63cf7
g-orchestrated: wire local AppAuth SPM dependency and Info.plist into…
w-goog Apr 17, 2026
c7c7188
g-orchestrated: changelog entry for SwiftUI SPM example
w-goog Apr 17, 2026
c211ab0
g-orchestrated: list Swift-Carthage and Swift-SPM examples in Example…
w-goog Apr 17, 2026
924a715
g-orchestrated: add README for SwiftUI + SPM sample
w-goog Apr 17, 2026
c5d9af7
Merge swiftui-spm-example-sources
w-goog Apr 17, 2026
ab0c5b7
Merge swiftui-spm-example-plist
w-goog Apr 17, 2026
b3a2ffe
Merge swiftui-spm-example-project
w-goog Apr 17, 2026
7998fc6
Merge swiftui-spm-example-docs
w-goog Apr 17, 2026
37c2637
fix(example): import Combine for @Published and ObservableObject
w-goog Apr 17, 2026
ca7ca4f
fix(example): remove bogus additionalHeaders arg from OIDRegistration…
w-goog Apr 17, 2026
160681c
First commit for new Swift sample app.
w-goog Apr 20, 2026
3d36e12
g-orchested: Add config values for identity providers.
w-goog Apr 21, 2026
688c81e
Add the weird little override for xcconfig's slashes
w-goog Apr 22, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Unreleased
- Add SwiftUI + Swift Package Manager sample app under `Examples/Example_Swift-SPM`.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we link the PR here? Some examples are in the bullets of the previous releases.


# 2.0.0
- Raise minimum supported iOS version to iOS 12. ([#918](https://github.com/openid/AppAuth-iOS/pull/918))
- Remove deprecated `[UIApplication openURL:]` method to compile with Xcode 16. ([#911](https://github.com/openid/AppAuth-iOS/pull/911))
Expand Down
1 change: 1 addition & 0 deletions Examples/Example_Swift-SPM/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Config/Example.local.xcconfig
14 changes: 14 additions & 0 deletions Examples/Example_Swift-SPM/Config/Example.xcconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// This file holds public placeholder defaults for OAuth configuration.
// Real OAuth client values belong in the sibling, gitignored Config/Example.local.xcconfig,
// which overrides these defaults via the optional-include directive below.

OIDC_ISSUER = https:/$()/issuer.example.com
OIDC_CLIENT_ID = YOUR_CLIENT_ID
OIDC_REDIRECT_URI = com.example.app:/oauth2redirect/example-provider
OIDC_REDIRECT_URI_SCHEME = com.example.app

// Code signing. Defaults to Automatic with no team. Override in
// Example.local.xcconfig if you need Manual signing with a specific provisioning profile.
CODE_SIGN_STYLE = Automatic

#include? "Example.local.xcconfig"
375 changes: 375 additions & 0 deletions Examples/Example_Swift-SPM/Example.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,375 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 77;
objects = {

/* Begin PBXBuildFile section */
09BB0F002F91B157004C0D4B /* AppAuth in Frameworks */ = {isa = PBXBuildFile; productRef = 09BB0E002F91B157004C0D4B /* AppAuth */; };
/* End PBXBuildFile section */

/* Begin PBXFileReference section */
09BB0B542F91B157004C0D4B /* Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Example.app; sourceTree = BUILT_PRODUCTS_DIR; };
09BB0F012F91B157004C0D4B /* Config/Example.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Config/Example.xcconfig; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFileSystemSynchronizedBuildFileExceptionSet section */
09BB0C002F91B157004C0D4B /* Exceptions for "Example" folder in "Example" target */ = {
isa = PBXFileSystemSynchronizedBuildFileExceptionSet;
membershipExceptions = (
Info.plist,
);
target = 09BB0B532F91B157004C0D4B /* Example */;
};
/* End PBXFileSystemSynchronizedBuildFileExceptionSet section */

/* Begin PBXFileSystemSynchronizedRootGroup section */
09BB0B562F91B157004C0D4B /* Example */ = {
isa = PBXFileSystemSynchronizedRootGroup;
exceptions = (
09BB0C002F91B157004C0D4B /* Exceptions for "Example" folder in "Example" target */,
);
path = Example;
sourceTree = "<group>";
};
/* End PBXFileSystemSynchronizedRootGroup section */

/* Begin PBXFrameworksBuildPhase section */
09BB0B512F91B157004C0D4B /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
09BB0F002F91B157004C0D4B /* AppAuth in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
09BB0B4B2F91B157004C0D4B = {
isa = PBXGroup;
children = (
09BB0F022F91B157004C0D4B /* Config */,
09BB0B562F91B157004C0D4B /* Example */,
09BB0B552F91B157004C0D4B /* Products */,
);
sourceTree = "<group>";
};
09BB0B552F91B157004C0D4B /* Products */ = {
isa = PBXGroup;
children = (
09BB0B542F91B157004C0D4B /* Example.app */,
);
name = Products;
sourceTree = "<group>";
};
09BB0F022F91B157004C0D4B /* Config */ = {
isa = PBXGroup;
children = (
09BB0F012F91B157004C0D4B /* Config/Example.xcconfig */,
);
name = Config;
sourceTree = "<group>";
};
/* End PBXGroup section */

/* Begin PBXNativeTarget section */
09BB0B532F91B157004C0D4B /* Example */ = {
isa = PBXNativeTarget;
buildConfigurationList = 09BB0B5F2F91B158004C0D4B /* Build configuration list for PBXNativeTarget "Example" */;
buildPhases = (
09BB0B502F91B157004C0D4B /* Sources */,
09BB0B512F91B157004C0D4B /* Frameworks */,
09BB0B522F91B157004C0D4B /* Resources */,
);
buildRules = (
);
dependencies = (
);
fileSystemSynchronizedGroups = (
09BB0B562F91B157004C0D4B /* Example */,
);
name = Example;
packageProductDependencies = (
09BB0E002F91B157004C0D4B /* AppAuth */,
);
productName = Example;
productReference = 09BB0B542F91B157004C0D4B /* Example.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */

/* Begin PBXProject section */
09BB0B4C2F91B157004C0D4B /* Project object */ = {
isa = PBXProject;
attributes = {
BuildIndependentTargetsInParallel = 1;
LastSwiftUpdateCheck = 2620;
LastUpgradeCheck = 2620;
TargetAttributes = {
09BB0B532F91B157004C0D4B = {
CreatedOnToolsVersion = 26.2;
};
};
};
buildConfigurationList = 09BB0B4F2F91B157004C0D4B /* Build configuration list for PBXProject "Example" */;
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = 09BB0B4B2F91B157004C0D4B;
minimizedProjectReferenceProxies = 1;
packageReferences = (
09BB0D002F91B157004C0D4B /* XCLocalSwiftPackageReference "../.." */,
);
preferredProjectObjectVersion = 77;
productRefGroup = 09BB0B552F91B157004C0D4B /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
09BB0B532F91B157004C0D4B /* Example */,
);
};
/* End PBXProject section */

/* Begin PBXResourcesBuildPhase section */
09BB0B522F91B157004C0D4B /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */

/* Begin PBXSourcesBuildPhase section */
09BB0B502F91B157004C0D4B /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */

/* Begin XCBuildConfiguration section */
09BB0B5D2F91B158004C0D4B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
ENABLE_USER_SCRIPT_SANDBOXING = YES;
GCC_C_LANGUAGE_STANDARD = gnu17;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 26.2;
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = "DEBUG $(inherited)";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
};
name = Debug;
};
09BB0B5E2F91B158004C0D4B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_USER_SCRIPT_SANDBOXING = YES;
GCC_C_LANGUAGE_STANDARD = gnu17;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 26.2;
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
SWIFT_COMPILATION_MODE = wholemodule;
VALIDATE_PRODUCT = YES;
};
name = Release;
};
09BB0B602F91B158004C0D4B /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 09BB0F012F91B157004C0D4B /* Config/Example.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CURRENT_PROJECT_VERSION = 1;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = NO;
INFOPLIST_FILE = Example/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = "AppAuth iOS Demo";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = com.google.experimental0.dev;
PRODUCT_NAME = "$(TARGET_NAME)";
STRING_CATALOG_GENERATE_SYMBOLS = YES;
SWIFT_APPROACHABLE_CONCURRENCY = YES;
SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor;
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
09BB0B612F91B158004C0D4B /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 09BB0F012F91B157004C0D4B /* Config/Example.xcconfig */;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CURRENT_PROJECT_VERSION = 1;
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = NO;
INFOPLIST_FILE = Example/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = "AppAuth iOS Demo";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = com.google.experimental0.dev;
PRODUCT_NAME = "$(TARGET_NAME)";
STRING_CATALOG_GENERATE_SYMBOLS = YES;
SWIFT_APPROACHABLE_CONCURRENCY = YES;
SWIFT_DEFAULT_ACTOR_ISOLATION = MainActor;
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_UPCOMING_FEATURE_MEMBER_IMPORT_VISIBILITY = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
/* End XCBuildConfiguration section */

/* Begin XCConfigurationList section */
09BB0B4F2F91B157004C0D4B /* Build configuration list for PBXProject "Example" */ = {
isa = XCConfigurationList;
buildConfigurations = (
09BB0B5D2F91B158004C0D4B /* Debug */,
09BB0B5E2F91B158004C0D4B /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
09BB0B5F2F91B158004C0D4B /* Build configuration list for PBXNativeTarget "Example" */ = {
isa = XCConfigurationList;
buildConfigurations = (
09BB0B602F91B158004C0D4B /* Debug */,
09BB0B612F91B158004C0D4B /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */

/* Begin XCLocalSwiftPackageReference section */
09BB0D002F91B157004C0D4B /* XCLocalSwiftPackageReference "../.." */ = {
isa = XCLocalSwiftPackageReference;
relativePath = ../..;
};
/* End XCLocalSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
09BB0E002F91B157004C0D4B /* AppAuth */ = {
isa = XCSwiftPackageProductDependency;
productName = AppAuth;
};
/* End XCSwiftPackageProductDependency section */
};
rootObject = 09BB0B4C2F91B157004C0D4B /* Project object */;
}
Loading
Loading