This is an example of a request to start a section in a bank using a ussd code
var ussddefault = "444"
var version = "1230628"
func Login(_ pin: String ,_ card :String) {
let encrypted = OfusCodeUSSD().code("0" + card + "*" + pin);
let operation = "40"
ExecuteUSSD ( "*" + ussddefault + "*" + operation + "*" + encrypted + "*" + version + "#")
}
func ExecuteUSSD(_ ussd: String){
if let url = URL(string: "telprompt:\(ussd)".urlEncoded), UIApplication.shared.canOpenURL(url) {
UIApplication.shared.open(url)
}
}