(runId: string)
| 77 | } |
| 78 | |
| 79 | async getRunResult(runId: string): Promise<TaskRunExecutionResult | undefined> { |
| 80 | try { |
| 81 | return await zodfetch( |
| 82 | TaskRunExecutionResult, |
| 83 | `${this.baseUrl}/api/v1/runs/${runId}/result`, |
| 84 | { |
| 85 | method: "GET", |
| 86 | headers: this.#getHeaders(false), |
| 87 | }, |
| 88 | zodFetchOptions |
| 89 | ); |
| 90 | } catch (error) { |
| 91 | if (error instanceof ApiError) { |
| 92 | if (error.status === 404) { |
| 93 | return undefined; |
| 94 | } |
| 95 | } |
| 96 | |
| 97 | throw error; |
| 98 | } |
| 99 | } |
| 100 | |
| 101 | async getBatchResults(batchId: string): Promise<BatchTaskRunExecutionResult | undefined> { |
| 102 | return await zodfetch( |
no test coverage detected