()
| 50 | } |
| 51 | |
| 52 | async whoAmI() { |
| 53 | if (!this.accessToken) { |
| 54 | throw new Error("whoAmI: No access token"); |
| 55 | } |
| 56 | |
| 57 | return wrapZodFetch(WhoAmIResponseSchema, `${this.apiURL}/api/v2/whoami`, { |
| 58 | headers: { |
| 59 | Authorization: `Bearer ${this.accessToken}`, |
| 60 | "Content-Type": "application/json", |
| 61 | }, |
| 62 | }); |
| 63 | } |
| 64 | |
| 65 | async getProject(projectRef: string) { |
| 66 | if (!this.accessToken) { |
no test coverage detected