class Spaceship::Tunes::AppSubmission
Represents a submission for review of an App
Store Connect Application
This class handles the submission of all review information and documents
Attributes
@deprecated Setted automatically by add_id_info_uses_idfa
usage @return (Boolean) Ad ID Info - Limits ads tracking DEPRECATED: Use add_id_info_uses_idfa
instead.
@return (Boolean) Ad ID Info - Serves ads
@return (Boolean) Ad ID Info - Tracks actions
@return (Boolean) Ad ID Info - Tracks installs
@return (Boolean) Ad ID Info - Uses idfa
@return (Spaceship::Tunes::Application
) A reference to the application
this submission is for
@return (Boolean) Content Rights - Contains third party content
@return (Boolean) Content Rights - Has rights of content
@return (Boolean) Export Compliance - Available on French Store
@return (Not Yet Implemented) Export Compliance - CCAT File
@return (Boolean) Export Compliance - Compliance Required
@return (Boolean) Export Compliance - Contains proprietary cryptography
@return (Boolean) Export Compliance - Contains third-party cryptography
@return (Boolean) Export Compliance - Encryption Updated
@return (Boolean) Export Compliance - Is exempt
@return (String
) Export Compliance - Platform
@return (Boolean) Export Compliance - Uses encryption
@return (String
) The platform of the device. This is usually “ios” @example
"appletvos"
@return (Boolean) Submitted for Review
@return (AppVersion
) The version to use for this submission
Private Class Methods
@param application (Spaceship::Tunes::Application
) The app this submission is for
# File spaceship/lib/spaceship/tunes/app_submission.rb, line 123 def create(application, version, platform: nil) attrs = client.prepare_app_submissions(application.apple_id, application.edit_version(platform: platform).version_id) attrs[:application] = application attrs[:version] = version attrs[:platform] = platform return self.factory(attrs) end
Create a new object based on a hash. This is used to create a new object based on the server response.
# File spaceship/lib/spaceship/tunes/app_submission.rb, line 105 def factory(attrs) # fill content rights section if iTC returns nil if attrs["contentRights"].nil? attrs["contentRights"] = { "containsThirdPartyContent" => { "value" => nil }, "hasRights" => { "value" => nil } } end obj = self.new(attrs) return obj end
Private Instance Methods
Save and complete the app submission
# File spaceship/lib/spaceship/tunes/app_submission.rb, line 134 def complete! raw_data_clone = raw_data.dup if self.content_rights_has_rights.nil? || self.content_rights_contains_third_party_content.nil? raw_data_clone.set(["contentRights"], nil) end raw_data_clone.delete(:version) raw_data_clone.delete(:application) # Check whether the application makes use of IDFA or not # and automatically set the mandatory limitsTracking value in the request JSON accordingly. if !self.add_id_info_uses_idfa.nil? && self.add_id_info_uses_idfa == true # Application uses IDFA, before sending for submission limitsTracking key in the request JSON must be set to true (agreement). raw_data_clone.set( ["adIdInfo", "limitsTracking", "value"], true ) end client.send_app_submission(application.apple_id, application.edit_version(platform: platform).version_id, raw_data_clone) @submitted_for_review = true end
# File spaceship/lib/spaceship/tunes/app_submission.rb, line 156 def setup @submitted_for_review = false end