dotnet user-secrets init
Use the dotnet user-secrets set
command to add your secrets. For example:
dotnet user-secrets set "ConnectionStrings:DefaultConnection" "YourConnectionStringHere"
dotnet user-secrets set "JwtKey" "YourJwtKeyHere"
To view all the stored User Secrets, use the following command:
dotnet user-secrets list
To remove a specific secret, use the following command:
dotnet user-secrets remove "SecretName"