saving serialized array to s3 objects (rather then plain text) and added refresh token functionality