EngineClient#

class gamspy.EngineClient(host: str, username: str | None = None, password: str | None = None, jwt: str | None = None, namespace: str = 'global', extra_model_files: list[str] = [], engine_options: dict | None = None, remove_results: bool = False, is_blocking: bool = True)[source]#

Bases: object

GAMS Engine Client.

Parameters:
hoststr

Host address.

usernamestr | None, optional

Username

passwordstr | None, optional

Password

jwtstr | None, optional

JWT Token

namespacestr, optional

Namespace, by default “global”

extra_model_fileslist[str], optional

extra_model_files, by default []

engine_optionsdict | None, optional

GAMS Engine options, by default None

remove_resultsbool, optional

Whether to remove the results from GAMS Engine Server, by default False

is_blockingbool, optional

Synchronous (blocking) or asynchronous, by default True

Examples

>>> import gamspy as gp
>>> client = gp.EngineClient(host="https://engine.gams.com/api/", username="<username>", password="<password>")