LegacySudoSiteReputationClient
public protocol LegacySudoSiteReputationClient
A library of functions for querying the reputation of a website using the Sudo Platform Site Reputation service.
-
getSiteReputation(url:
Asynchronous) Checks the reputation of the provided URL.
Declaration
Swift
func getSiteReputation(url: String) async throws -> LegacySiteReputation
Parameters
url
The URL that will be checked.
-
update()
AsynchronousRetrieves the latest site reputation data from the Sudo Platform Site Reputation service.
Declaration
Swift
func update() async throws
Parameters
throws
Called once when reputation data has been updated or an error occurs.
-
lastUpdatePerformedAt()
AsynchronousThe timestamp of the site reputation data fetched by the last call to
update
, ornil
if there is no site reputation data stored locally.Declaration
Swift
func lastUpdatePerformedAt() async -> Date?
-
clearStorage()
AsynchronousClears all locally cached data created by the SudoSiteReputation SDK. Cancels any in-progress calls to
update
, causing them to return an error.Declaration
Swift
func clearStorage() async throws