fastlane 2.149.0 → 2.150.0.rc4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (94) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +82 -82
  3. data/deliver/lib/deliver.rb +0 -1
  4. data/deliver/lib/deliver/app_screenshot.rb +26 -25
  5. data/deliver/lib/deliver/options.rb +6 -11
  6. data/deliver/lib/deliver/runner.rb +7 -21
  7. data/deliver/lib/deliver/setup.rb +5 -30
  8. data/deliver/lib/deliver/submit_for_review.rb +155 -90
  9. data/deliver/lib/deliver/upload_metadata.rb +355 -143
  10. data/deliver/lib/deliver/upload_price_tier.rb +22 -8
  11. data/deliver/lib/deliver/upload_screenshots.rb +134 -39
  12. data/fastlane/lib/fastlane/actions/docs/capture_ios_screenshots.md +1 -1
  13. data/fastlane/lib/fastlane/actions/docs/upload_to_app_store.md.erb +77 -96
  14. data/fastlane/lib/fastlane/actions/docs/upload_to_play_store.md +3 -2
  15. data/fastlane/lib/fastlane/actions/download_dsyms.rb +7 -1
  16. data/fastlane/lib/fastlane/actions/google_play_track_release_names.rb +74 -0
  17. data/fastlane/lib/fastlane/actions/set_changelog.rb +23 -20
  18. data/fastlane/lib/fastlane/actions/slack.rb +1 -1
  19. data/fastlane/lib/fastlane/actions/spm.rb +7 -0
  20. data/fastlane/lib/fastlane/actions/upload_symbols_to_crashlytics.rb +1 -32
  21. data/fastlane/lib/fastlane/lane.rb +3 -3
  22. data/fastlane/lib/fastlane/swift_fastlane_function.rb +8 -4
  23. data/fastlane/lib/fastlane/version.rb +1 -1
  24. data/fastlane/swift/ControlCommand.swift +1 -0
  25. data/fastlane/swift/Deliverfile.swift +1 -1
  26. data/fastlane/swift/Fastlane.swift +48 -12
  27. data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/xcshareddata/xcschemes/FastlaneRunner.xcscheme +3 -9
  28. data/fastlane/swift/Gymfile.swift +1 -1
  29. data/fastlane/swift/LaneFileProtocol.swift +2 -5
  30. data/fastlane/swift/Matchfile.swift +1 -1
  31. data/fastlane/swift/MatchfileProtocol.swift +1 -1
  32. data/fastlane/swift/Precheckfile.swift +1 -1
  33. data/fastlane/swift/RubyCommand.swift +29 -6
  34. data/fastlane/swift/RubyCommandable.swift +1 -0
  35. data/fastlane/swift/Runner.swift +85 -13
  36. data/fastlane/swift/Scanfile.swift +1 -1
  37. data/fastlane/swift/ScanfileProtocol.swift +1 -1
  38. data/fastlane/swift/Screengrabfile.swift +1 -1
  39. data/fastlane/swift/Snapshotfile.swift +1 -1
  40. data/fastlane/swift/SnapshotfileProtocol.swift +3 -3
  41. data/fastlane/swift/SocketClient.swift +76 -45
  42. data/fastlane/swift/SocketClientDelegateProtocol.swift +1 -1
  43. data/fastlane/swift/SocketResponse.swift +1 -0
  44. data/fastlane_core/lib/fastlane_core/configuration/config_item.rb +1 -3
  45. data/fastlane_core/lib/fastlane_core/itunes_transporter.rb +89 -52
  46. data/fastlane_core/lib/fastlane_core/pkg_file_analyser.rb +7 -0
  47. data/fastlane_core/lib/fastlane_core/project.rb +0 -1
  48. data/frameit/lib/frameit/device_types.rb +100 -100
  49. data/produce/lib/produce/itunes_connect.rb +32 -21
  50. data/produce/lib/produce/options.rb +3 -3
  51. data/sigh/lib/assets/resign.sh +7 -7
  52. data/snapshot/lib/assets/SnapshotHelper.swift +5 -5
  53. data/snapshot/lib/assets/SnapshotHelperXcode8.swift +3 -3
  54. data/snapshot/lib/snapshot/options.rb +0 -1
  55. data/snapshot/lib/snapshot/reports_generator.rb +8 -1
  56. data/spaceship/lib/spaceship/.DS_Store +0 -0
  57. data/spaceship/lib/spaceship/client.rb +4 -3
  58. data/spaceship/lib/spaceship/connect_api.rb +25 -2
  59. data/spaceship/lib/spaceship/connect_api/client.rb +97 -31
  60. data/spaceship/lib/spaceship/connect_api/file_uploader.rb +98 -0
  61. data/spaceship/lib/spaceship/connect_api/model.rb +1 -1
  62. data/spaceship/lib/spaceship/connect_api/models/age_rating_declaration.rb +113 -0
  63. data/spaceship/lib/spaceship/connect_api/models/app.rb +120 -3
  64. data/spaceship/lib/spaceship/connect_api/models/app_category.rb +94 -0
  65. data/spaceship/lib/spaceship/connect_api/models/app_info.rb +67 -0
  66. data/spaceship/lib/spaceship/connect_api/models/app_info_localization.rb +38 -0
  67. data/spaceship/lib/spaceship/connect_api/models/app_preview.rb +129 -0
  68. data/spaceship/lib/spaceship/connect_api/models/app_preview_set.rb +71 -0
  69. data/spaceship/lib/spaceship/connect_api/models/app_price.rb +22 -0
  70. data/spaceship/lib/spaceship/connect_api/models/app_price_tier.rb +12 -0
  71. data/spaceship/lib/spaceship/connect_api/models/app_review_attachment.rb +71 -0
  72. data/spaceship/lib/spaceship/connect_api/models/app_screenshot.rb +93 -0
  73. data/spaceship/lib/spaceship/connect_api/models/app_screenshot_set.rb +101 -0
  74. data/spaceship/lib/spaceship/connect_api/models/app_store_review_detail.rb +51 -0
  75. data/spaceship/lib/spaceship/connect_api/models/app_store_version.rb +183 -0
  76. data/spaceship/lib/spaceship/connect_api/models/app_store_version_localization.rb +86 -0
  77. data/spaceship/lib/spaceship/connect_api/models/app_store_version_phased_release.rb +36 -0
  78. data/spaceship/lib/spaceship/connect_api/models/app_store_version_submission.rb +26 -0
  79. data/spaceship/lib/spaceship/connect_api/models/build.rb +4 -0
  80. data/spaceship/lib/spaceship/connect_api/models/idfa_declaration.rb +40 -0
  81. data/spaceship/lib/spaceship/connect_api/models/reset_ratings_request.rb +26 -0
  82. data/spaceship/lib/spaceship/connect_api/models/territory.rb +27 -0
  83. data/spaceship/lib/spaceship/connect_api/testflight/testflight.rb +10 -3
  84. data/spaceship/lib/spaceship/connect_api/tunes/client.rb +33 -0
  85. data/spaceship/lib/spaceship/connect_api/tunes/tunes.rb +841 -0
  86. data/spaceship/lib/spaceship/spaceauth_runner.rb +2 -2
  87. data/supply/lib/supply/client.rb +19 -0
  88. data/supply/lib/supply/reader.rb +16 -0
  89. metadata +44 -39
  90. data/deliver/lib/deliver/upload_assets.rb +0 -27
  91. data/fastlane/lib/assets/.s3_html_template.erb.swp +0 -0
  92. data/fastlane/lib/fastlane/actions/.hipchat.rb.swp +0 -0
  93. data/fastlane/lib/fastlane/actions/.slack.rb.swp +0 -0
  94. data/scan/lib/scan/.options.rb.swp +0 -0
@@ -0,0 +1,129 @@
1
+ require_relative '../model'
2
+ require_relative '../file_uploader'
3
+ require 'spaceship/globals'
4
+
5
+ require 'digest/md5'
6
+
7
+ module Spaceship
8
+ class ConnectAPI
9
+ class AppPreview
10
+ include Spaceship::ConnectAPI::Model
11
+
12
+ attr_accessor :file_size
13
+ attr_accessor :file_name
14
+ attr_accessor :source_file_checksum
15
+ attr_accessor :preview_frame_time_code
16
+ attr_accessor :mime_type
17
+ attr_accessor :video_url
18
+ attr_accessor :preview_image
19
+ attr_accessor :upload_operations
20
+ attr_accessor :asset_deliver_state
21
+ attr_accessor :upload
22
+
23
+ attr_mapping({
24
+ "fileSize" => "file_size",
25
+ "fileName" => "file_name",
26
+ "sourceFileChecksum" => "source_file_checksum",
27
+ "previewFrameTimeCode" => "preview_frame_time_code",
28
+ "mimeType" => "mime_type",
29
+ "videoUrl" => "video_url",
30
+ "previewImage" => "preview_image",
31
+ "uploadOperations" => "upload_operations",
32
+ "assetDeliveryState" => "asset_delivery_state",
33
+ "uploaded" => "uploaded"
34
+ })
35
+
36
+ def self.type
37
+ return "appPreviews"
38
+ end
39
+
40
+ def complete?
41
+ (asset_delivery_state || {})["state"] == "COMPLETE"
42
+ end
43
+
44
+ #
45
+ # API
46
+ #
47
+
48
+ def self.get(app_preview_id: nil)
49
+ Spaceship::ConnectAPI.get_app_preview(app_preview_id: app_preview_id).first
50
+ end
51
+
52
+ # Creates an AppPreview in an AppPreviewSet
53
+ # Setting the optional frame_time_code will force polling until video is done processing
54
+ # @param app_preview_set_id The AppPreviewSet id
55
+ # @param path The path of the file
56
+ # @param frame_time_code The time code for the preview still frame (ex: "00:00:07:01")
57
+ def self.create(app_preview_set_id: nil, path: nil, frame_time_code: nil)
58
+ require 'faraday'
59
+
60
+ filename = File.basename(path)
61
+ filesize = File.size(path)
62
+ bytes = File.binread(path)
63
+
64
+ post_attributes = {
65
+ fileSize: filesize,
66
+ fileName: filename
67
+ }
68
+
69
+ # Create placeholder
70
+ preview = Spaceship::ConnectAPI.post_app_preview(
71
+ app_preview_set_id: app_preview_set_id,
72
+ attributes: post_attributes
73
+ ).to_models.first
74
+
75
+ # Upload the file
76
+ upload_operations = preview.upload_operations
77
+ Spaceship::ConnectAPI::FileUploader.upload(upload_operations, bytes)
78
+
79
+ # Update file uploading complete
80
+ patch_attributes = {
81
+ uploaded: true,
82
+ sourceFileChecksum: Digest::MD5.hexdigest(bytes)
83
+ }
84
+
85
+ begin
86
+ preview = Spaceship::ConnectAPI.patch_app_preview(
87
+ app_preview_id: preview.id,
88
+ attributes: patch_attributes
89
+ ).to_models.first
90
+ rescue => error
91
+ puts("Failed to patch app preview. Update may have gone through so verifying") if Spaceship::Globals.verbose?
92
+
93
+ preview = Spaceship::ConnectAPI::AppPreview.get(app_preview_id: preview.id)
94
+ raise error unless preview.complete?
95
+ end
96
+
97
+ # Poll for video processing completion to set still frame time
98
+ unless frame_time_code.nil?
99
+ loop do
100
+ unless preview.video_url.nil?
101
+ puts("Preview processing complete!") if Spaceship::Globals.verbose?
102
+ preview = preview.update(attributes: {
103
+ previewFrameTimeCode: frame_time_code
104
+ })
105
+ puts("Updated preview frame time code!") if Spaceship::Globals.verbose?
106
+ break
107
+ end
108
+
109
+ sleep_time = 30
110
+ puts("Waiting #{sleep_time} seconds before checking status of processing...") if Spaceship::Globals.verbose?
111
+ sleep(sleep_time)
112
+
113
+ preview = Spaceship::ConnectAPI::AppPreview.get(app_preview_id: preview.id)
114
+ end
115
+ end
116
+
117
+ preview
118
+ end
119
+
120
+ def update(attributes: nil)
121
+ Spaceship::ConnectAPI.patch_app_preview(app_preview_id: id, attributes: attributes)
122
+ end
123
+
124
+ def delete!(filter: {}, includes: nil, limit: nil, sort: nil)
125
+ Spaceship::ConnectAPI.delete_app_preview(app_preview_id: id)
126
+ end
127
+ end
128
+ end
129
+ end
@@ -0,0 +1,71 @@
1
+ require_relative '../model'
2
+ require_relative './app_preview'
3
+
4
+ module Spaceship
5
+ class ConnectAPI
6
+ class AppPreviewSet
7
+ include Spaceship::ConnectAPI::Model
8
+
9
+ attr_accessor :preview_type
10
+
11
+ attr_accessor :app_previews
12
+
13
+ module PreviewType
14
+ IPHONE_35 = "IPHONE_35"
15
+ IPHONE_40 = "IPHONE_40"
16
+ IPHONE_47 = "IPHONE_47"
17
+ IPHONE_55 = "IPHONE_55"
18
+ IPHONE_58 = "IPHONE_58"
19
+ IPHONE_65 = "IPHONE_65"
20
+
21
+ IPAD_97 = "IPAD_97"
22
+ IPAD_105 = "IPAD_105"
23
+ IPAD_PRO_3GEN_11 = "IPAD_PRO_3GEN_11"
24
+ IPAD_PRO_129 = "IPAD_PRO_129"
25
+ IPAD_PRO_3GEN_129 = "IPAD_PRO_3GEN_129"
26
+
27
+ DESKTOP = "DESKTOP"
28
+
29
+ ALL = [
30
+ IPHONE_35,
31
+ IPHONE_40,
32
+ IPHONE_47,
33
+ IPHONE_55,
34
+ IPHONE_58,
35
+ IPHONE_65,
36
+
37
+ IPAD_97,
38
+ IPAD_105,
39
+ IPAD_PRO_3GEN_11,
40
+ IPAD_PRO_129,
41
+ IPAD_PRO_3GEN_129,
42
+
43
+ DESKTOP
44
+ ]
45
+ end
46
+
47
+ attr_mapping({
48
+ "previewType" => "preview_type",
49
+
50
+ "appPreviews" => "app_previews"
51
+ })
52
+
53
+ def self.type
54
+ return "appPreviewSets"
55
+ end
56
+
57
+ #
58
+ # API
59
+ #
60
+
61
+ def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
62
+ resp = Spaceship::ConnectAPI.get_app_preview_sets(filter: filter, includes: includes, limit: limit, sort: sort)
63
+ return resp.to_models
64
+ end
65
+
66
+ def upload_preview(path: nil, frame_time_code: nil)
67
+ return Spaceship::ConnectAPI::AppPreview.create(app_preview_set_id: id, path: path, frame_time_code: frame_time_code)
68
+ end
69
+ end
70
+ end
71
+ end
@@ -0,0 +1,22 @@
1
+ require_relative '../model'
2
+ module Spaceship
3
+ class ConnectAPI
4
+ class AppPrice
5
+ include Spaceship::ConnectAPI::Model
6
+
7
+ attr_accessor :start_date
8
+
9
+ attr_accessor :price_tier
10
+
11
+ attr_mapping({
12
+ "startDate" => "start_date",
13
+
14
+ "priceTier" => "price_tier"
15
+ })
16
+
17
+ def self.type
18
+ return "appPrices"
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,12 @@
1
+ require_relative '../model'
2
+ module Spaceship
3
+ class ConnectAPI
4
+ class AppPriceTier
5
+ include Spaceship::ConnectAPI::Model
6
+
7
+ def self.type
8
+ return "appPriceTiers"
9
+ end
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,71 @@
1
+ require_relative '../model'
2
+ require_relative '../file_uploader'
3
+ require 'digest/md5'
4
+
5
+ module Spaceship
6
+ class ConnectAPI
7
+ class AppReviewAttachment
8
+ include Spaceship::ConnectAPI::Model
9
+
10
+ attr_accessor :file_name
11
+ attr_accessor :source_file_checksum
12
+ attr_accessor :upload_operations
13
+ attr_accessor :asset_delivery_state
14
+ attr_accessor :uploaded
15
+
16
+ attr_mapping({
17
+ "fileName" => "file_name",
18
+ "sourceFileChecksum" => "source_file_checksum",
19
+ "uploadOperations" => "upload_operations",
20
+ "assetDeliveryState" => "asset_delivery_state",
21
+ "uploaded" => "uploaded"
22
+ })
23
+
24
+ def self.type
25
+ return "appReviewAttachments"
26
+ end
27
+
28
+ #
29
+ # API
30
+ #
31
+
32
+ def self.create(app_store_review_detail_id: nil, path: nil)
33
+ require 'faraday'
34
+
35
+ filename = File.basename(path)
36
+ filesize = File.size(path)
37
+ bytes = File.binread(path)
38
+
39
+ post_attributes = {
40
+ fileSize: filesize,
41
+ fileName: filename
42
+ }
43
+
44
+ # Create placeholder
45
+ attachment = Spaceship::ConnectAPI.post_app_review_attachment(
46
+ app_store_review_detail_id: app_store_review_detail_id,
47
+ attributes: post_attributes
48
+ ).to_models.first
49
+
50
+ # Upload the file
51
+ upload_operations = attachment.upload_operations
52
+ Spaceship::ConnectAPI::FileUploader.upload(upload_operations, bytes)
53
+
54
+ # Update file uploading complete
55
+ patch_attributes = {
56
+ uploaded: true,
57
+ sourceFileChecksum: Digest::MD5.hexdigest(bytes)
58
+ }
59
+
60
+ Spaceship::ConnectAPI.patch_app_review_attachment(
61
+ app_review_attachment_id: attachment.id,
62
+ attributes: patch_attributes
63
+ ).to_models.first
64
+ end
65
+
66
+ def delete!(filter: {}, includes: nil, limit: nil, sort: nil)
67
+ Spaceship::ConnectAPI.delete_app_review_attachment(app_review_attachment_id: id)
68
+ end
69
+ end
70
+ end
71
+ end
@@ -0,0 +1,93 @@
1
+ require_relative '../model'
2
+ require_relative '../file_uploader'
3
+ require 'spaceship/globals'
4
+
5
+ require 'digest/md5'
6
+
7
+ module Spaceship
8
+ class ConnectAPI
9
+ class AppScreenshot
10
+ include Spaceship::ConnectAPI::Model
11
+
12
+ attr_accessor :file_name
13
+ attr_accessor :source_file_checksum
14
+ attr_accessor :image_asset
15
+ attr_accessor :asset_token
16
+ attr_accessor :asset_type
17
+ attr_accessor :upload_operations
18
+ attr_accessor :asset_delivery_state
19
+ attr_accessor :uploaded
20
+
21
+ attr_mapping({
22
+ "fileName" => "file_name",
23
+ "sourceFileChecksum" => "source_file_checksum",
24
+ "imageAsset" => "image_asset",
25
+ "assetToken" => "asset_token",
26
+ "assetType" => "asset_type",
27
+ "uploadOperations" => "upload_operations",
28
+ "assetDeliveryState" => "asset_delivery_state",
29
+ "uploaded" => "uploaded"
30
+ })
31
+
32
+ def self.type
33
+ return "appScreenshots"
34
+ end
35
+
36
+ def complete?
37
+ (asset_delivery_state || {})["state"] == "COMPLETE"
38
+ end
39
+
40
+ #
41
+ # API
42
+ #
43
+ #
44
+
45
+ def self.create(app_screenshot_set_id: nil, path: nil)
46
+ require 'faraday'
47
+
48
+ filename = File.basename(path)
49
+ filesize = File.size(path)
50
+ bytes = File.binread(path)
51
+
52
+ post_attributes = {
53
+ fileSize: filesize,
54
+ fileName: filename
55
+ }
56
+
57
+ # Create placeholder
58
+ screenshot = Spaceship::ConnectAPI.post_app_screenshot(
59
+ app_screenshot_set_id: app_screenshot_set_id,
60
+ attributes: post_attributes
61
+ ).first
62
+
63
+ # Upload the file
64
+ upload_operations = screenshot.upload_operations
65
+ Spaceship::ConnectAPI::FileUploader.upload(upload_operations, bytes)
66
+
67
+ # Update file uploading complete
68
+ patch_attributes = {
69
+ uploaded: true,
70
+ sourceFileChecksum: Digest::MD5.hexdigest(bytes)
71
+ }
72
+
73
+ begin
74
+ screenshot = Spaceship::ConnectAPI.patch_app_screenshot(
75
+ app_screenshot_id: screenshot.id,
76
+ attributes: patch_attributes
77
+ ).first
78
+ rescue => error
79
+ puts("Failed to patch app screenshot. Update may have gone through so verifying") if Spaceship::Globals.verbose?
80
+
81
+ screenshot = Spaceship::ConnectAPI.get_app_screenshot(app_screenshot_id: screenshot.id).first
82
+ raise error unless screenshot.complete?
83
+ end
84
+
85
+ return screenshot
86
+ end
87
+
88
+ def delete!(filter: {}, includes: nil, limit: nil, sort: nil)
89
+ Spaceship::ConnectAPI.delete_app_screenshot(app_screenshot_id: id)
90
+ end
91
+ end
92
+ end
93
+ end
@@ -0,0 +1,101 @@
1
+ require_relative '../model'
2
+ require_relative './app_screenshot'
3
+
4
+ module Spaceship
5
+ class ConnectAPI
6
+ class AppScreenshotSet
7
+ include Spaceship::ConnectAPI::Model
8
+
9
+ attr_accessor :screenshot_display_type
10
+
11
+ attr_accessor :app_screenshots
12
+
13
+ module DisplayType
14
+ APP_IPHONE_35 = "APP_IPHONE_35"
15
+ APP_IPHONE_40 = "APP_IPHONE_40"
16
+ APP_IPHONE_47 = "APP_IPHONE_47"
17
+ APP_IPHONE_55 = "APP_IPHONE_55"
18
+ APP_IPHONE_58 = "APP_IPHONE_58"
19
+ APP_IPHONE_65 = "APP_IPHONE_65"
20
+
21
+ APP_IPAD_97 = "APP_IPAD_97"
22
+ APP_IPAD_105 = "APP_IPAD_105"
23
+ APP_IPAD_PRO_3GEN_11 = "APP_IPAD_PRO_3GEN_11"
24
+ APP_IPAD_PRO_129 = "APP_IPAD_PRO_129"
25
+ APP_IPAD_PRO_3GEN_129 = "APP_IPAD_PRO_3GEN_129"
26
+
27
+ IMESSAGE_APP_IPHONE_40 = "IMESSAGE_APP_IPHONE_40"
28
+ IMESSAGE_APP_IPHONE_47 = "IMESSAGE_APP_IPHONE_47"
29
+ IMESSAGE_APP_IPHONE_55 = "IMESSAGE_APP_IPHONE_55"
30
+ IMESSAGE_APP_IPHONE_58 = "IMESSAGE_APP_IPHONE_58"
31
+ IMESSAGE_APP_IPHONE_65 = "IMESSAGE_APP_IPHONE_65"
32
+
33
+ IMESSAGE_APP_IPAD_97 = "IMESSAGE_APP_IPAD_97"
34
+ IMESSAGE_APP_IPAD_105 = "IMESSAGE_APP_IPAD_105"
35
+ IMESSAGE_APP_IPAD_PRO_129 = "IMESSAGE_APP_IPAD_PRO_129"
36
+ IMESSAGE_APP_IPAD_PRO_3GEN_11 = "IMESSAGE_APP_IPAD_PRO_3GEN_11"
37
+ IMESSAGE_APP_IPAD_PRO_3GEN_129 = "IMESSAGE_APP_IPAD_PRO_3GEN_129"
38
+
39
+ APP_WATCH_SERIES_3 = "APP_WATCH_SERIES_3"
40
+ APP_WATCH_SERIES_4 = "APP_WATCH_SERIES_4"
41
+
42
+ APP_DESKTOP = "APP_DESKTOP"
43
+
44
+ ALL = [
45
+ APP_IPHONE_35,
46
+ APP_IPHONE_40,
47
+ APP_IPHONE_47,
48
+ APP_IPHONE_55,
49
+ APP_IPHONE_58,
50
+ APP_IPHONE_65,
51
+
52
+ APP_IPAD_97,
53
+ APP_IPAD_105,
54
+ APP_IPAD_PRO_3GEN_11,
55
+ APP_IPAD_PRO_129,
56
+ APP_IPAD_PRO_3GEN_129,
57
+
58
+ IMESSAGE_APP_IPHONE_40,
59
+ IMESSAGE_APP_IPHONE_47,
60
+ IMESSAGE_APP_IPHONE_55,
61
+ IMESSAGE_APP_IPHONE_58,
62
+ IMESSAGE_APP_IPHONE_65,
63
+
64
+ IMESSAGE_APP_IPAD_97,
65
+ IMESSAGE_APP_IPAD_105,
66
+ IMESSAGE_APP_IPAD_PRO_129,
67
+ IMESSAGE_APP_IPAD_PRO_3GEN_11,
68
+ IMESSAGE_APP_IPAD_PRO_3GEN_129,
69
+
70
+ APP_WATCH_SERIES_3,
71
+ APP_WATCH_SERIES_4,
72
+
73
+ APP_DESKTOP
74
+ ]
75
+ end
76
+
77
+ attr_mapping({
78
+ "screenshotDisplayType" => "screenshot_display_type",
79
+
80
+ "appScreenshots" => "app_screenshots"
81
+ })
82
+
83
+ def self.type
84
+ return "appScreenshotSets"
85
+ end
86
+
87
+ #
88
+ # API
89
+ #
90
+
91
+ def self.all(filter: {}, includes: nil, limit: nil, sort: nil)
92
+ resp = Spaceship::ConnectAPI.get_app_screenshot_sets(filter: filter, includes: includes, limit: limit, sort: sort)
93
+ return resp.to_models
94
+ end
95
+
96
+ def upload_screenshot(path: nil)
97
+ return Spaceship::ConnectAPI::AppScreenshot.create(app_screenshot_set_id: id, path: path)
98
+ end
99
+ end
100
+ end
101
+ end