InShorts class

Main class to interact with InShorts API.

Constructors

InShorts()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

getLanguage(Language language) String
Returns the internal string representation for a Language.
getNews({required NewsType newsType, Language language = Language.en, int limit = 10, Client? client}) Future<Data>
Fetches news from InShorts based on the provided newsType and language.
getNewsEndPoint({required NewsType newsType, Language language = Language.en, int limit = 10}) String
Constructs the API endpoint URL for the given parameters.
getNewsTitle(NewsType newsType) String
Returns a human-readable title for a NewsType.
getNewsType(NewsType newsType) String
Returns the internal string representation for a NewsType.