Closed elprl closed 4 months ago
Also getting the following concatenation typo: "status code 400Your credit balance is too low to access the Claude API. Please go to Plans & Billing to upgrade or purchase credits."
Here is what I'm doing currently:
extension SwiftAnthropic.APIError: LocalizedError, CustomStringConvertible {
public var description: String {
return displayDescription
}
/// A localized message describing what error occurred.
public var errorDescription: String? {
return displayDescription
}
}
Would you be open to create a pull request for this change? :)
I've edited the file and created the PR, but I've done no testing on this update.
#18
Can I suggest updating the APIError so that we can use error.localizedDescription, e.g.:
rather than creating a new property 'displayDescription' .