()
| 14 | } |
| 15 | |
| 16 | async getHttpClient() { |
| 17 | if (this._httpClient) { |
| 18 | return this._httpClient; |
| 19 | } |
| 20 | this._httpClient = ky.create({ |
| 21 | timeout: 50000, // Set timeout, wallet requests should not exceed 50 seconds. If they do, it's likely due to poor urchain server design |
| 22 | retry: 0, |
| 23 | prefixUrl: this._host, |
| 24 | headers: { |
| 25 | Authorization: `Bearer ${this._apiKey}`, |
| 26 | }, |
| 27 | }); |
| 28 | return this._httpClient; |
| 29 | } |
| 30 | |
| 31 | _parseResponse(data) { |
| 32 | return data; |