Description
Is your feature request related to a problem? Please describe.
At times a Swift application needs to do the following for itself:
-
Configure AWS Amplify Gen 2 Swift application using
AmplifyOutputsData.init
since these settings are stored in a secure & encrypted manner and other than in JSON file (i.e.amplify_outputs.json
) or JSON representation. -
Fetching these configuration settings so that the application's behavior can be adapted based on those settings or present them to the application's users.
Showing to users the AWS region, authentication properties & policies, name of the AWS S3 bucket & region, ... can be useful for them.
Additionally, the application can have specific behaviors based on the values of those settings.
Describe the solution you'd like
The removal of the @_spi(InternalAmplifyConfiguration)
on the struct AmplifyOutputsData
as well as various sub-structures and functions.
Doing this will make this accessible to Swift developers using AWS Amplify Gen 2.
Describe alternatives you've considered
What I've done is to copied the code of struct AmplifyOutputsData
as well as various sub-structures and functions within my application code to avoid naming collision with Amplify
module. But, where the @_spi(...)
directive is commented out.
I've tried to workaround by using a different import directive the application such as @_spi(InternalAmplifyConfiguration) import Amplify
, but Swift fails to compile stating that the AmplifyOutputsData
is internal.
Is the feature request related to any of the existing Amplify categories?
No response
Additional context
The first point of being able to use AmplifyOutputsData.init
is practical for those such as myself when developing an applications used the medical domain, since our best practices is store configuration in a secure manner such as iOS Keychain.
In that context being able to initialize a AmplifyOutputsData
object with the appropriate settings without having to compose into an intermediary JSON representation is practical.
Thanks for your consideration.