トップレベルの SDK エントリポイント。クライアントおよびサーバーのファクトリを再エクスポートし、サーバーを起動してそこへ接続済みのクライアントを返す便利ヘルパー createOpencode を提供する。
Methods
(static) createOpencode(optionsopt) → {Promise.<{client: OpencodeClient, server: {url: string, close: function()}}>}
closedcode サーバーを起動し、それに接続済みのクライアントを返す。
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
options | Object | <optional> | createOpencodeServer に転送されるサーバーオプション(hostname、port、timeout、config、signal)。 |
Returns:
接続済みのクライアントと稼働中のサーバーハンドル。
- Type:
- Promise.<{client: OpencodeClient, server: {url: string, close: function()}}>