adamrushy / OpenAISwift

This is a wrapper library around the ChatGPT and OpenAI HTTP API
MIT License
1.6k stars 242 forks source link

authToken doesn't work in version 1.4 #109

Open matanstau opened 11 months ago

matanstau commented 11 months ago

let openAI = OpenAISwift(authToken: "TOKEN") doesn't work anymore in version 1.4

Mmanion commented 11 months ago

I believe you may be referring to https://github.com/adamrushy/OpenAISwift/issues/102

matanstau commented 11 months ago

Thanks that solved that. I'm still getting some issues with version 1.4 The same code that use to work is now returning "The operation couldn’t be completed. (OpenAISwift.OpenAIError error 2.)"

ChickenRei commented 11 months ago

Me to, Have you solved it by now ?

matanstau commented 11 months ago

Not really

marcoboerner commented 10 months ago

I think there is an undocumented change, to initialize it you have to use: let openAI = OpenAISwift(config: .makeDefaultOpenAI(apiKey: "TOKEN"))

laszlotuss commented 10 months ago

These are two separate issues, which I both fixed and made a Pull Request #114