spaceship/lib/spaceship/connect_api/client.rb in fastlane-2.164.0 vs spaceship/lib/spaceship/connect_api/client.rb in fastlane-2.165.0
- old
+ new
@@ -11,23 +11,26 @@
attr_accessor :tunes_client
attr_accessor :portal_client
# Initializes client with Apple's App Store Connect JWT auth key.
#
- # This method will automatically use the key id, issuer id, and filepath from environment
+ # This method will automatically use the arguments from environment
# variables if not given.
#
- # All three parameters are needed to authenticate.
+ # The key_id, issuer_id and either filepath or key are needed to authenticate.
#
# @param key_id (String) (optional): The key id
# @param issuer_id (String) (optional): The issuer id
# @param filepath (String) (optional): The filepath
+ # @param key (String) (optional): The key
+ # @param duration (Integer) (optional): How long this session should last
+ # @param in_house (Boolean) (optional): Whether this session is an Enterprise one
#
# @raise InvalidUserCredentialsError: raised if authentication failed
#
# @return (Spaceship::ConnectAPI::Client) The client the login method was called for
- def self.auth(key_id: nil, issuer_id: nil, filepath: nil)
- token = Spaceship::ConnectAPI::Token.create(key_id: key_id, issuer_id: issuer_id, filepath: filepath)
+ def self.auth(key_id: nil, issuer_id: nil, filepath: nil, key: nil, duration: nil, in_house: nil)
+ token = Spaceship::ConnectAPI::Token.create(key_id: key_id, issuer_id: issuer_id, filepath: filepath, key: key, duration: duration, in_house: in_house)
return ConnectAPI::Client.new(token: token)
end
# Authenticates with Apple's web services. This method has to be called once
# to generate a valid session.