diff --git a/Sources/StudentVue/SOAPApi/StudentVueApi.swift b/Sources/StudentVue/SOAPApi/StudentVueApi.swift index 168ccdc..1b6463f 100644 --- a/Sources/StudentVue/SOAPApi/StudentVueApi.swift +++ b/Sources/StudentVue/SOAPApi/StudentVueApi.swift @@ -187,7 +187,7 @@ public class StudentVueApi { /// - Throws: `Error` some other error has occured when api request was sent /// /// - Returns: Success or not - public func checkCredentials() async throws -> Bool { + internal func checkCredentials() async throws -> Bool { do { _ = try await xmlServiceRequest(methodName: .getSoundFileData) diff --git a/Sources/StudentVue/StudentVue.swift b/Sources/StudentVue/StudentVue.swift index 22b884f..d036364 100644 --- a/Sources/StudentVue/StudentVue.swift +++ b/Sources/StudentVue/StudentVue.swift @@ -48,4 +48,13 @@ public class StudentVue { self.api.updateCredentials(domain: domain, username: username, password: password) self.scraper.updateCredentials(domain: domain, username: username, password: password) } + + /// Checks validity of user credentials quickly + /// + /// - Throws: `Error` some other error has occured when api request was sent + /// + /// - Returns: Success or not + public func checkCredentials() async throws -> Bool { + return try await api.checkCredentials() + } }