View JoinChannelAudioEntry.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let audio = Audio() | |
let symblAI = SymblAI(with: "enter_token_here") | |
override func viewDidAppear(_ animated: Bool) { | |
super.viewDidAppear(animated) | |
// Stop audio recording if it has been started | |
if audio.isRunning { | |
do { | |
let sound = try audio.stop() |
View JoinChannelAudioEntry.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self?.symblAI.transcript(for: upload, { transcript in | |
print(transcript) | |
}) |
View JoinChannelAudioEntry.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self?.symblAI.status(for: upload) { status in | |
print(status) | |
} |
View JoinChannelAudioEntry.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// start uploading to symbl.ai | |
symblAI.upload(sound) { result in | |
switch result { | |
case .success(let upload): | |
print(upload) | |
case .failure(let error): | |
print(error) | |
} | |
} |
View JoinChannelAudioEntry.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let audio = Audio() | |
let symblAI = SymblAI(with: "enter_token_here") | |
override func viewDidAppear(_ animated: Bool) { | |
super.viewDidAppear(animated) | |
// Stop audio recording if it has been started | |
if audio.isRunning { | |
do { | |
let sound = try audio.stop() |
View SymblAI.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// SymblAI.swift | |
// APIExample | |
// | |
// Created by Shams Ahmed on 29/03/2021. | |
// Copyright © 2021 Agora Corp. All rights reserved. | |
// | |
import Foundation | |
import Combine |
View Audio.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Audio.swift | |
// APIExample | |
// | |
// Created by Shams Ahmed on 29/03/2021. | |
// Copyright © 2021 Agora Corp. All rights reserved. | |
// | |
import CoreAudio | |
import AVKit |
View connect_to_ios.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"action": "connect", | |
"from": "447418340557", | |
"endpoint": [ | |
{ | |
"type": "app", | |
"user": "shams" | |
} | |
] |
View gist:b15b7f6eb8a23c0ab7dad5f4c914af96
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"action": "connect", | |
"from": "447418340557", | |
"endpoint": [ | |
{ | |
"type": "app", | |
"user": "ios" | |
} | |
] |
NewerOlder