Skip to content

Commit

Permalink
SDK regeneration
Browse files Browse the repository at this point in the history
  • Loading branch information
fern-api[bot] committed Mar 20, 2024
1 parent 28b3504 commit ac627c4
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 7 deletions.
2 changes: 1 addition & 1 deletion assemblyai.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ require_relative "lib/gemconfig"

Gem::Specification.new do |spec|
spec.name = "assemblyai"
spec.version = "1.0.0-beta.5"
spec.version = "1.0.0-beta.6"
spec.authors = AssemblyAI::Gemconfig::AUTHORS
spec.email = AssemblyAI::Gemconfig::EMAIL
spec.summary = AssemblyAI::Gemconfig::SUMMARY
Expand Down
8 changes: 4 additions & 4 deletions lib/assemblyai/files/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def initialize(request_client:)

# Upload your media file directly to the AssemblyAI API if it isn't accessible via a URL already.
#
# @param request [String] Base64 encoded bytes
# @param request [String, IO] Base64 encoded bytes, or an IO object (e.g. Faraday::UploadIO, etc.)
# @param request_options [RequestOptions]
# @return [Files::UploadedFile]
def upload(request:, request_options: nil)
Expand All @@ -26,7 +26,7 @@ def upload(request:, request_options: nil)
req.headers["Authorization"] = request_options.api_key unless request_options&.api_key.nil?
req.headers = { **req.headers, **(request_options&.additional_headers || {}) }.compact
req.headers["Content-Type"] = "application/octet-stream"
req.body = { **(request || {}), **(request_options&.additional_body_parameters || {}) }.compact
req.body = request
end
Files::UploadedFile.from_json(json_object: response.body)
end
Expand All @@ -44,7 +44,7 @@ def initialize(request_client:)

# Upload your media file directly to the AssemblyAI API if it isn't accessible via a URL already.
#
# @param request [String] Base64 encoded bytes
# @param request [String, IO] Base64 encoded bytes, or an IO object (e.g. Faraday::UploadIO, etc.)
# @param request_options [RequestOptions]
# @return [Files::UploadedFile]
def upload(request:, request_options: nil)
Expand All @@ -54,7 +54,7 @@ def upload(request:, request_options: nil)
req.headers["Authorization"] = request_options.api_key unless request_options&.api_key.nil?
req.headers = { **req.headers, **(request_options&.additional_headers || {}) }.compact
req.headers["Content-Type"] = "application/octet-stream"
req.body = { **(request || {}), **(request_options&.additional_body_parameters || {}) }.compact
req.body = request
end
Files::UploadedFile.from_json(json_object: response.body)
end
Expand Down
11 changes: 11 additions & 0 deletions lib/assemblyai/realtime/types/realtime.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# frozen_string_literal: true

module AssemblyAI
class Realtime
# The encoding of the audio data
class Realtime
PCM_S16LE = "pcm_s16le"
PCM_MULAW = "pcm_mulaw"
end
end
end
4 changes: 2 additions & 2 deletions lib/requests.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def initialize(api_key:, environment: Environment::DEFAULT, max_retries: nil, ti
@headers = {
"X-Fern-Language": "Ruby",
"X-Fern-SDK-Name": "assemblyai",
"X-Fern-SDK-Version": "1.0.0-beta.5",
"X-Fern-SDK-Version": "1.0.0-beta.6",
"Authorization": api_key.to_s
}
@conn = Faraday.new(@base_url, headers: @headers) do |faraday|
Expand All @@ -46,7 +46,7 @@ def initialize(api_key:, environment: Environment::DEFAULT, max_retries: nil, ti
@headers = {
"X-Fern-Language": "Ruby",
"X-Fern-SDK-Name": "assemblyai",
"X-Fern-SDK-Version": "1.0.0-beta.5",
"X-Fern-SDK-Version": "1.0.0-beta.6",
"Authorization": api_key.to_s
}
@conn = Faraday.new(@base_url, headers: @headers) do |faraday|
Expand Down
1 change: 1 addition & 0 deletions lib/types_export.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
require_relative "assemblyai/transcripts/types/transcript_list_item"
require_relative "assemblyai/transcripts/types/transcript_list"
require_relative "assemblyai/transcripts/types/audio_intelligence_model_status"
require_relative "assemblyai/realtime/types/realtime"
require_relative "assemblyai/realtime/types/session_begins"
require_relative "assemblyai/realtime/types/partial_transcript"
require_relative "assemblyai/realtime/types/final_transcript"
Expand Down

0 comments on commit ac627c4

Please sign in to comment.