shotstack 0.1.5 → 0.1.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +4 -4
  2. data/lib/shotstack/api/edit_api.rb +224 -0
  3. data/lib/shotstack/api/endpoints_api.rb +1 -1
  4. data/lib/shotstack/api/serve_api.rb +224 -0
  5. data/lib/shotstack/api_client.rb +1 -1
  6. data/lib/shotstack/api_error.rb +1 -1
  7. data/lib/shotstack/configuration.rb +16 -2
  8. data/lib/shotstack/models/asset_render_response.rb +222 -0
  9. data/lib/shotstack/models/asset_response.rb +219 -0
  10. data/lib/shotstack/models/asset_response_attributes.rb +334 -0
  11. data/lib/shotstack/models/asset_response_data.rb +229 -0
  12. data/lib/shotstack/models/audio_asset.rb +1 -1
  13. data/lib/shotstack/models/clip.rb +17 -8
  14. data/lib/shotstack/models/crop.rb +1 -1
  15. data/lib/shotstack/models/destinations.rb +17 -0
  16. data/lib/shotstack/models/edit.rb +65 -7
  17. data/lib/shotstack/models/flip_transformation.rb +234 -0
  18. data/lib/shotstack/models/font.rb +2 -2
  19. data/lib/shotstack/models/html_asset.rb +3 -3
  20. data/lib/shotstack/models/image_asset.rb +2 -2
  21. data/lib/shotstack/models/luma_asset.rb +4 -4
  22. data/lib/shotstack/models/merge_field.rb +236 -0
  23. data/lib/shotstack/models/offset.rb +1 -1
  24. data/lib/shotstack/models/output.rb +71 -19
  25. data/lib/shotstack/models/poster.rb +1 -1
  26. data/lib/shotstack/models/probe_response.rb +255 -0
  27. data/lib/shotstack/models/queued_response.rb +2 -1
  28. data/lib/shotstack/models/queued_response_data.rb +2 -1
  29. data/lib/shotstack/models/range.rb +3 -3
  30. data/lib/shotstack/models/render_response.rb +2 -1
  31. data/lib/shotstack/models/render_response_data.rb +6 -5
  32. data/lib/shotstack/models/rotate_transformation.rb +222 -0
  33. data/lib/shotstack/models/shotstack_destination.rb +240 -0
  34. data/lib/shotstack/models/size.rb +278 -0
  35. data/lib/shotstack/models/skew_transformation.rb +234 -0
  36. data/lib/shotstack/models/soundtrack.rb +1 -1
  37. data/lib/shotstack/models/thumbnail.rb +2 -2
  38. data/lib/shotstack/models/timeline.rb +18 -6
  39. data/lib/shotstack/models/title_asset.rb +1 -1
  40. data/lib/shotstack/models/track.rb +1 -1
  41. data/lib/shotstack/models/transformation.rb +237 -0
  42. data/lib/shotstack/models/transition.rb +7 -7
  43. data/lib/shotstack/models/video_asset.rb +1 -1
  44. data/lib/shotstack/version.rb +2 -2
  45. data/lib/shotstack.rb +15 -1
  46. data/shotstack.gemspec +2 -2
  47. metadata +25 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fbe23e5f4a04895111959fadb1ae057a20d64b47b3015f4ac8cad2481b83f077
4
- data.tar.gz: da6e99e80bea597ef2e65a5bf09bafcecd4923015fcc3ba1dbffda46306006c0
3
+ metadata.gz: e9c1ddaba061aa41da26da530d278ab2ff9239268111a56aedd4a717114030e6
4
+ data.tar.gz: f3e7cffc5cbaefa285b48927d45f741cb27176f95dfc9c804b568407a8843a03
5
5
  SHA512:
6
- metadata.gz: 69581b3a2c839530874857f0964f62cb01adb0a28c8dd04bfd65f142d172eb6465ddddf43d1fc80d55108301c7ab60a7b3939ee9903868842c5241e6314bf904
7
- data.tar.gz: 1106311ee9c828f029679471cc02899342c3054927176e0c6e9b2b2cb7b433afa21f1dd997ef787df1cfbd9e9dddf3868f1497fcae89313bb6a25120c4829e00
6
+ metadata.gz: 1a8c458a14834895ca0b889df64602048133a445d3b746cb9d6f0999e16c18a1f74f70d98a2818a1dca9d4dffd29af4110240e45cb642e95601ab151387fda14
7
+ data.tar.gz: dbc5351392e398c9ed963c5ce69e1b115db6d5f7a97401dc1c06c2c8972dfa11b3653b6756599b33c85ce1a8694f280ac0b7024794db210467f363ab05852a7e
@@ -0,0 +1,224 @@
1
+ =begin
2
+ #Shotstack
3
+
4
+ #Shotstack is a video, image and audio editing service that allows for the automated generation of videos, images and audio using JSON and a RESTful API. You arrange and configure an edit and POST it to the API which will render your media and provide a file location when complete. For more details visit [shotstack.io](https://shotstack.io) or checkout our [getting started](https://shotstack.gitbook.io/docs/guides/getting-started) documentation. There are two main API's, one for editing and generating assets (Edit API) and one for managing hosted assets (Serve API). The Edit API base URL is: <b>https://api.shotstack.io/{version}</b> The Serve API base URL is: <b>https://api.shotstack.io/serve/{version}</b>
5
+
6
+ The version of the OpenAPI document: v1
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module Shotstack
16
+ class EditApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Get Render Status
23
+ # Get the rendering status, temporary asset url and details of a render by ID. **Base URL:** https://api.shotstack.io/{version}
24
+ # @param id [String] The id of the timeline render task in UUID format
25
+ # @param [Hash] opts the optional parameters
26
+ # @option opts [Boolean] :data Include the data parameter in the response. The data parameter includes the original timeline, output and other settings sent to the API.&lt;br&gt;&lt;br&gt;&lt;b&gt;Note:&lt;/b&gt; the default is currently &#x60;true&#x60;, this is deprecated and the default will soon be &#x60;false&#x60;. If you rely on the data being returned in the response you should explicitly set the parameter to &#x60;true&#x60;.
27
+ # @option opts [Boolean] :merged Used when data is set to true, it will show the [merge fields](#tocs_mergefield) merged in to the data response.
28
+ # @return [RenderResponse]
29
+ def get_render(id, opts = {})
30
+ data, _status_code, _headers = get_render_with_http_info(id, opts)
31
+ data
32
+ end
33
+
34
+ # Get Render Status
35
+ # Get the rendering status, temporary asset url and details of a render by ID. **Base URL:** https://api.shotstack.io/{version}
36
+ # @param id [String] The id of the timeline render task in UUID format
37
+ # @param [Hash] opts the optional parameters
38
+ # @option opts [Boolean] :data Include the data parameter in the response. The data parameter includes the original timeline, output and other settings sent to the API.&lt;br&gt;&lt;br&gt;&lt;b&gt;Note:&lt;/b&gt; the default is currently &#x60;true&#x60;, this is deprecated and the default will soon be &#x60;false&#x60;. If you rely on the data being returned in the response you should explicitly set the parameter to &#x60;true&#x60;.
39
+ # @option opts [Boolean] :merged Used when data is set to true, it will show the [merge fields](#tocs_mergefield) merged in to the data response.
40
+ # @return [Array<(RenderResponse, Integer, Hash)>] RenderResponse data, response status code and response headers
41
+ def get_render_with_http_info(id, opts = {})
42
+ if @api_client.config.debugging
43
+ @api_client.config.logger.debug 'Calling API: EditApi.get_render ...'
44
+ end
45
+ # verify the required parameter 'id' is set
46
+ if @api_client.config.client_side_validation && id.nil?
47
+ fail ArgumentError, "Missing the required parameter 'id' when calling EditApi.get_render"
48
+ end
49
+ pattern = Regexp.new(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/)
50
+ if @api_client.config.client_side_validation && id !~ pattern
51
+ fail ArgumentError, "invalid value for 'id' when calling EditApi.get_render, must conform to the pattern #{pattern}."
52
+ end
53
+
54
+ # resource path
55
+ local_var_path = '/render/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
56
+
57
+ # query parameters
58
+ query_params = opts[:query_params] || {}
59
+ query_params[:'data'] = opts[:'data'] if !opts[:'data'].nil?
60
+ query_params[:'merged'] = opts[:'merged'] if !opts[:'merged'].nil?
61
+
62
+ # header parameters
63
+ header_params = opts[:header_params] || {}
64
+ # HTTP header 'Accept' (if needed)
65
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
66
+
67
+ # form parameters
68
+ form_params = opts[:form_params] || {}
69
+
70
+ # http body (model)
71
+ post_body = opts[:debug_body]
72
+
73
+ # return_type
74
+ return_type = opts[:debug_return_type] || 'RenderResponse'
75
+
76
+ # auth_names
77
+ auth_names = opts[:debug_auth_names] || ['DeveloperKey']
78
+
79
+ new_options = opts.merge(
80
+ :operation => :"EditApi.get_render",
81
+ :header_params => header_params,
82
+ :query_params => query_params,
83
+ :form_params => form_params,
84
+ :body => post_body,
85
+ :auth_names => auth_names,
86
+ :return_type => return_type
87
+ )
88
+
89
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
90
+ if @api_client.config.debugging
91
+ @api_client.config.logger.debug "API called: EditApi#get_render\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
92
+ end
93
+ return data, status_code, headers
94
+ end
95
+
96
+ # Render Asset
97
+ # Queue and render the contents of a timeline as a video, image or audio file. **Base URL:** https://api.shotstack.io/{version}
98
+ # @param edit [Edit] The video, image or audio edit specified using JSON.
99
+ # @param [Hash] opts the optional parameters
100
+ # @return [QueuedResponse]
101
+ def post_render(edit, opts = {})
102
+ data, _status_code, _headers = post_render_with_http_info(edit, opts)
103
+ data
104
+ end
105
+
106
+ # Render Asset
107
+ # Queue and render the contents of a timeline as a video, image or audio file. **Base URL:** https://api.shotstack.io/{version}
108
+ # @param edit [Edit] The video, image or audio edit specified using JSON.
109
+ # @param [Hash] opts the optional parameters
110
+ # @return [Array<(QueuedResponse, Integer, Hash)>] QueuedResponse data, response status code and response headers
111
+ def post_render_with_http_info(edit, opts = {})
112
+ if @api_client.config.debugging
113
+ @api_client.config.logger.debug 'Calling API: EditApi.post_render ...'
114
+ end
115
+ # verify the required parameter 'edit' is set
116
+ if @api_client.config.client_side_validation && edit.nil?
117
+ fail ArgumentError, "Missing the required parameter 'edit' when calling EditApi.post_render"
118
+ end
119
+ # resource path
120
+ local_var_path = '/render'
121
+
122
+ # query parameters
123
+ query_params = opts[:query_params] || {}
124
+
125
+ # header parameters
126
+ header_params = opts[:header_params] || {}
127
+ # HTTP header 'Accept' (if needed)
128
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
129
+ # HTTP header 'Content-Type'
130
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
131
+
132
+ # form parameters
133
+ form_params = opts[:form_params] || {}
134
+
135
+ # http body (model)
136
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(edit)
137
+
138
+ # return_type
139
+ return_type = opts[:debug_return_type] || 'QueuedResponse'
140
+
141
+ # auth_names
142
+ auth_names = opts[:debug_auth_names] || ['DeveloperKey']
143
+
144
+ new_options = opts.merge(
145
+ :operation => :"EditApi.post_render",
146
+ :header_params => header_params,
147
+ :query_params => query_params,
148
+ :form_params => form_params,
149
+ :body => post_body,
150
+ :auth_names => auth_names,
151
+ :return_type => return_type
152
+ )
153
+
154
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
155
+ if @api_client.config.debugging
156
+ @api_client.config.logger.debug "API called: EditApi#post_render\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
157
+ end
158
+ return data, status_code, headers
159
+ end
160
+
161
+ # Inspect Media
162
+ # Inspects any media asset (image, video, audio) on the internet using a hosted version of [FFprobe](https://ffmpeg.org/ffprobe.html). The probe endpoint returns useful information about an asset such as width, height, duration, rotation, framerate, etc... **Base URL:** https://api.shotstack.io/{version}
163
+ # @param url [String] The URL of the media to inspect, must be **URL encoded**.
164
+ # @param [Hash] opts the optional parameters
165
+ # @return [ProbeResponse]
166
+ def probe(url, opts = {})
167
+ data, _status_code, _headers = probe_with_http_info(url, opts)
168
+ data
169
+ end
170
+
171
+ # Inspect Media
172
+ # Inspects any media asset (image, video, audio) on the internet using a hosted version of [FFprobe](https://ffmpeg.org/ffprobe.html). The probe endpoint returns useful information about an asset such as width, height, duration, rotation, framerate, etc... **Base URL:** https://api.shotstack.io/{version}
173
+ # @param url [String] The URL of the media to inspect, must be **URL encoded**.
174
+ # @param [Hash] opts the optional parameters
175
+ # @return [Array<(ProbeResponse, Integer, Hash)>] ProbeResponse data, response status code and response headers
176
+ def probe_with_http_info(url, opts = {})
177
+ if @api_client.config.debugging
178
+ @api_client.config.logger.debug 'Calling API: EditApi.probe ...'
179
+ end
180
+ # verify the required parameter 'url' is set
181
+ if @api_client.config.client_side_validation && url.nil?
182
+ fail ArgumentError, "Missing the required parameter 'url' when calling EditApi.probe"
183
+ end
184
+ # resource path
185
+ local_var_path = '/probe/{url}'.sub('{' + 'url' + '}', CGI.escape(url.to_s))
186
+
187
+ # query parameters
188
+ query_params = opts[:query_params] || {}
189
+
190
+ # header parameters
191
+ header_params = opts[:header_params] || {}
192
+ # HTTP header 'Accept' (if needed)
193
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
194
+
195
+ # form parameters
196
+ form_params = opts[:form_params] || {}
197
+
198
+ # http body (model)
199
+ post_body = opts[:debug_body]
200
+
201
+ # return_type
202
+ return_type = opts[:debug_return_type] || 'ProbeResponse'
203
+
204
+ # auth_names
205
+ auth_names = opts[:debug_auth_names] || ['DeveloperKey']
206
+
207
+ new_options = opts.merge(
208
+ :operation => :"EditApi.probe",
209
+ :header_params => header_params,
210
+ :query_params => query_params,
211
+ :form_params => form_params,
212
+ :body => post_body,
213
+ :auth_names => auth_names,
214
+ :return_type => return_type
215
+ )
216
+
217
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
218
+ if @api_client.config.debugging
219
+ @api_client.config.logger.debug "API called: EditApi#probe\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
220
+ end
221
+ return data, status_code, headers
222
+ end
223
+ end
224
+ end
@@ -1,7 +1,7 @@
1
1
  =begin
2
2
  #Shotstack
3
3
 
4
- #The Shotstack API is a video editing service that allows for the automated creation of videos using JSON. You can configure an edit and POST it to the Shotstack API which will render your video and provide a file location when complete. For more details check https://shotstack.io
4
+ #The Shotstack API is a video editing service that allows for the automated creation of videos using JSON. You can configure an edit and POST it to the Shotstack API which will render your video and provide a file location when complete. For more details visit [shotstack.io](https://shotstack.io) or checkout our [getting started](https://shotstack.gitbook.io/docs/guides/getting-started) documentation.
5
5
 
6
6
  The version of the OpenAPI document: v1
7
7
 
@@ -0,0 +1,224 @@
1
+ =begin
2
+ #Shotstack
3
+
4
+ #Shotstack is a video, image and audio editing service that allows for the automated generation of videos, images and audio using JSON and a RESTful API. You arrange and configure an edit and POST it to the API which will render your media and provide a file location when complete. For more details visit [shotstack.io](https://shotstack.io) or checkout our [getting started](https://shotstack.gitbook.io/docs/guides/getting-started) documentation. There are two main API's, one for editing and generating assets (Edit API) and one for managing hosted assets (Serve API). The Edit API base URL is: <b>https://api.shotstack.io/{version}</b> The Serve API base URL is: <b>https://api.shotstack.io/serve/{version}</b>
5
+
6
+ The version of the OpenAPI document: v1
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module Shotstack
16
+ class ServeApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Delete Asset
23
+ # Delete an asset by its asset id. If a render creates multiple assets, such as thumbnail and poster images, each asset must be deleted individually by the asset id. **Base URL:** https://api.shotstack.io/serve/{version}
24
+ # @param id [String] The id of the asset in UUID format
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [nil]
27
+ def delete_asset(id, opts = {})
28
+ delete_asset_with_http_info(id, opts)
29
+ nil
30
+ end
31
+
32
+ # Delete Asset
33
+ # Delete an asset by its asset id. If a render creates multiple assets, such as thumbnail and poster images, each asset must be deleted individually by the asset id. **Base URL:** https://api.shotstack.io/serve/{version}
34
+ # @param id [String] The id of the asset in UUID format
35
+ # @param [Hash] opts the optional parameters
36
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
37
+ def delete_asset_with_http_info(id, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: ServeApi.delete_asset ...'
40
+ end
41
+ # verify the required parameter 'id' is set
42
+ if @api_client.config.client_side_validation && id.nil?
43
+ fail ArgumentError, "Missing the required parameter 'id' when calling ServeApi.delete_asset"
44
+ end
45
+ pattern = Regexp.new(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/)
46
+ if @api_client.config.client_side_validation && id !~ pattern
47
+ fail ArgumentError, "invalid value for 'id' when calling ServeApi.delete_asset, must conform to the pattern #{pattern}."
48
+ end
49
+
50
+ # resource path
51
+ local_var_path = '/assets/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
52
+
53
+ # query parameters
54
+ query_params = opts[:query_params] || {}
55
+
56
+ # header parameters
57
+ header_params = opts[:header_params] || {}
58
+
59
+ # form parameters
60
+ form_params = opts[:form_params] || {}
61
+
62
+ # http body (model)
63
+ post_body = opts[:debug_body]
64
+
65
+ # return_type
66
+ return_type = opts[:debug_return_type]
67
+
68
+ # auth_names
69
+ auth_names = opts[:debug_auth_names] || ['DeveloperKey']
70
+
71
+ new_options = opts.merge(
72
+ :operation => :"ServeApi.delete_asset",
73
+ :header_params => header_params,
74
+ :query_params => query_params,
75
+ :form_params => form_params,
76
+ :body => post_body,
77
+ :auth_names => auth_names,
78
+ :return_type => return_type
79
+ )
80
+
81
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
82
+ if @api_client.config.debugging
83
+ @api_client.config.logger.debug "API called: ServeApi#delete_asset\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
84
+ end
85
+ return data, status_code, headers
86
+ end
87
+
88
+ # Get Asset
89
+ # The Serve API is used to interact with, and delete hosted assets including videos, images, audio files, thumbnails and poster images. Use this endpoint to fetch an asset by asset id. Note that an asset id is unique for each asset and different from the render id. **Base URL:** https://api.shotstack.io/serve/{version}
90
+ # @param id [String] The id of the asset in UUID format
91
+ # @param [Hash] opts the optional parameters
92
+ # @return [AssetResponse]
93
+ def get_asset(id, opts = {})
94
+ data, _status_code, _headers = get_asset_with_http_info(id, opts)
95
+ data
96
+ end
97
+
98
+ # Get Asset
99
+ # The Serve API is used to interact with, and delete hosted assets including videos, images, audio files, thumbnails and poster images. Use this endpoint to fetch an asset by asset id. Note that an asset id is unique for each asset and different from the render id. **Base URL:** https://api.shotstack.io/serve/{version}
100
+ # @param id [String] The id of the asset in UUID format
101
+ # @param [Hash] opts the optional parameters
102
+ # @return [Array<(AssetResponse, Integer, Hash)>] AssetResponse data, response status code and response headers
103
+ def get_asset_with_http_info(id, opts = {})
104
+ if @api_client.config.debugging
105
+ @api_client.config.logger.debug 'Calling API: ServeApi.get_asset ...'
106
+ end
107
+ # verify the required parameter 'id' is set
108
+ if @api_client.config.client_side_validation && id.nil?
109
+ fail ArgumentError, "Missing the required parameter 'id' when calling ServeApi.get_asset"
110
+ end
111
+ pattern = Regexp.new(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/)
112
+ if @api_client.config.client_side_validation && id !~ pattern
113
+ fail ArgumentError, "invalid value for 'id' when calling ServeApi.get_asset, must conform to the pattern #{pattern}."
114
+ end
115
+
116
+ # resource path
117
+ local_var_path = '/assets/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
118
+
119
+ # query parameters
120
+ query_params = opts[:query_params] || {}
121
+
122
+ # header parameters
123
+ header_params = opts[:header_params] || {}
124
+ # HTTP header 'Accept' (if needed)
125
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
126
+
127
+ # form parameters
128
+ form_params = opts[:form_params] || {}
129
+
130
+ # http body (model)
131
+ post_body = opts[:debug_body]
132
+
133
+ # return_type
134
+ return_type = opts[:debug_return_type] || 'AssetResponse'
135
+
136
+ # auth_names
137
+ auth_names = opts[:debug_auth_names] || ['DeveloperKey']
138
+
139
+ new_options = opts.merge(
140
+ :operation => :"ServeApi.get_asset",
141
+ :header_params => header_params,
142
+ :query_params => query_params,
143
+ :form_params => form_params,
144
+ :body => post_body,
145
+ :auth_names => auth_names,
146
+ :return_type => return_type
147
+ )
148
+
149
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
150
+ if @api_client.config.debugging
151
+ @api_client.config.logger.debug "API called: ServeApi#get_asset\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
152
+ end
153
+ return data, status_code, headers
154
+ end
155
+
156
+ # Get Asset by Render ID
157
+ # A render may generate more than one file, such as a video, thumbnail and poster image. When the assets are created the only known id is the render id returned by the original [render request](#render-video), status request or webhook. This endpoint lets you look up one or more assets by the render id. **Base URL:** https://api.shotstack.io/serve/{version}
158
+ # @param id [String] The render id associated with the asset in UUID format
159
+ # @param [Hash] opts the optional parameters
160
+ # @return [AssetRenderResponse]
161
+ def get_asset_by_render_id(id, opts = {})
162
+ data, _status_code, _headers = get_asset_by_render_id_with_http_info(id, opts)
163
+ data
164
+ end
165
+
166
+ # Get Asset by Render ID
167
+ # A render may generate more than one file, such as a video, thumbnail and poster image. When the assets are created the only known id is the render id returned by the original [render request](#render-video), status request or webhook. This endpoint lets you look up one or more assets by the render id. **Base URL:** https://api.shotstack.io/serve/{version}
168
+ # @param id [String] The render id associated with the asset in UUID format
169
+ # @param [Hash] opts the optional parameters
170
+ # @return [Array<(AssetRenderResponse, Integer, Hash)>] AssetRenderResponse data, response status code and response headers
171
+ def get_asset_by_render_id_with_http_info(id, opts = {})
172
+ if @api_client.config.debugging
173
+ @api_client.config.logger.debug 'Calling API: ServeApi.get_asset_by_render_id ...'
174
+ end
175
+ # verify the required parameter 'id' is set
176
+ if @api_client.config.client_side_validation && id.nil?
177
+ fail ArgumentError, "Missing the required parameter 'id' when calling ServeApi.get_asset_by_render_id"
178
+ end
179
+ pattern = Regexp.new(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/)
180
+ if @api_client.config.client_side_validation && id !~ pattern
181
+ fail ArgumentError, "invalid value for 'id' when calling ServeApi.get_asset_by_render_id, must conform to the pattern #{pattern}."
182
+ end
183
+
184
+ # resource path
185
+ local_var_path = '/assets/render/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
186
+
187
+ # query parameters
188
+ query_params = opts[:query_params] || {}
189
+
190
+ # header parameters
191
+ header_params = opts[:header_params] || {}
192
+ # HTTP header 'Accept' (if needed)
193
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
194
+
195
+ # form parameters
196
+ form_params = opts[:form_params] || {}
197
+
198
+ # http body (model)
199
+ post_body = opts[:debug_body]
200
+
201
+ # return_type
202
+ return_type = opts[:debug_return_type] || 'AssetRenderResponse'
203
+
204
+ # auth_names
205
+ auth_names = opts[:debug_auth_names] || ['DeveloperKey']
206
+
207
+ new_options = opts.merge(
208
+ :operation => :"ServeApi.get_asset_by_render_id",
209
+ :header_params => header_params,
210
+ :query_params => query_params,
211
+ :form_params => form_params,
212
+ :body => post_body,
213
+ :auth_names => auth_names,
214
+ :return_type => return_type
215
+ )
216
+
217
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
218
+ if @api_client.config.debugging
219
+ @api_client.config.logger.debug "API called: ServeApi#get_asset_by_render_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
220
+ end
221
+ return data, status_code, headers
222
+ end
223
+ end
224
+ end
@@ -1,7 +1,7 @@
1
1
  =begin
2
2
  #Shotstack
3
3
 
4
- #The Shotstack API is a video editing service that allows for the automated creation of videos using JSON. You can configure an edit and POST it to the Shotstack API which will render your video and provide a file location when complete. For more details check https://shotstack.io
4
+ #Shotstack is a video, image and audio editing service that allows for the automated generation of videos, images and audio using JSON and a RESTful API. You arrange and configure an edit and POST it to the API which will render your media and provide a file location when complete. For more details visit [shotstack.io](https://shotstack.io) or checkout our [getting started](https://shotstack.gitbook.io/docs/guides/getting-started) documentation. There are two main API's, one for editing and generating assets (Edit API) and one for managing hosted assets (Serve API). The Edit API base URL is: <b>https://api.shotstack.io/{version}</b> The Serve API base URL is: <b>https://api.shotstack.io/serve/{version}</b>
5
5
 
6
6
  The version of the OpenAPI document: v1
7
7
 
@@ -1,7 +1,7 @@
1
1
  =begin
2
2
  #Shotstack
3
3
 
4
- #The Shotstack API is a video editing service that allows for the automated creation of videos using JSON. You can configure an edit and POST it to the Shotstack API which will render your video and provide a file location when complete. For more details check https://shotstack.io
4
+ #Shotstack is a video, image and audio editing service that allows for the automated generation of videos, images and audio using JSON and a RESTful API. You arrange and configure an edit and POST it to the API which will render your media and provide a file location when complete. For more details visit [shotstack.io](https://shotstack.io) or checkout our [getting started](https://shotstack.gitbook.io/docs/guides/getting-started) documentation. There are two main API's, one for editing and generating assets (Edit API) and one for managing hosted assets (Serve API). The Edit API base URL is: <b>https://api.shotstack.io/{version}</b> The Serve API base URL is: <b>https://api.shotstack.io/serve/{version}</b>
5
5
 
6
6
  The version of the OpenAPI document: v1
7
7
 
@@ -1,7 +1,7 @@
1
1
  =begin
2
2
  #Shotstack
3
3
 
4
- #The Shotstack API is a video editing service that allows for the automated creation of videos using JSON. You can configure an edit and POST it to the Shotstack API which will render your video and provide a file location when complete. For more details check https://shotstack.io
4
+ #Shotstack is a video, image and audio editing service that allows for the automated generation of videos, images and audio using JSON and a RESTful API. You arrange and configure an edit and POST it to the API which will render your media and provide a file location when complete. For more details visit [shotstack.io](https://shotstack.io) or checkout our [getting started](https://shotstack.gitbook.io/docs/guides/getting-started) documentation. There are two main API's, one for editing and generating assets (Edit API) and one for managing hosted assets (Serve API). The Edit API base URL is: <b>https://api.shotstack.io/{version}</b> The Serve API base URL is: <b>https://api.shotstack.io/serve/{version}</b>
5
5
 
6
6
  The version of the OpenAPI document: v1
7
7
 
@@ -231,7 +231,21 @@ module Shotstack
231
231
  description: "No description provided",
232
232
  variables: {
233
233
  version: {
234
- description: "No description provided",
234
+ description: "Set the stage to `v1` for production usage without watermarks. Set to `stage` to use the development sandbox.",
235
+ default_value: "v1",
236
+ enum_values: [
237
+ "v1",
238
+ "stage"
239
+ ]
240
+ }
241
+ }
242
+ },
243
+ {
244
+ url: "https://api.shotstack.io/serve/{version}",
245
+ description: "No description provided",
246
+ variables: {
247
+ version: {
248
+ description: "Set the stage to `v1` for production usage. Set to `stage` to use the development sandbox.",
235
249
  default_value: "v1",
236
250
  enum_values: [
237
251
  "v1",