diff --git a/.stats.yml b/.stats.yml index 87b67de..031a738 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,2 +1,2 @@ configured_endpoints: 111 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/gitpod%2Fgitpod-36f9d46890bf3667f5a6529bdb156fe1560834ad8187c4271aa0b0024de1adb5.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/gitpod%2Fgitpod-a058dd6f8c83b32adb6f30bae2db8295468b8ffc391342a960ec6f393c50b83e.yml diff --git a/src/resources/editors.ts b/src/resources/editors.ts index 5cd857f..58913f3 100644 --- a/src/resources/editors.ts +++ b/src/resources/editors.ts @@ -37,40 +37,40 @@ export class Editors extends APIResource { export type EditorsEditorsPage = EditorsPage; export interface Editor { - id?: string; + id: string; - alias?: string; + alias: string; - iconUrl?: string; + iconUrl: string; - installationInstructions?: string; + installationInstructions: string; - name?: string; + name: string; - shortDescription?: string; + shortDescription: string; - urlTemplate?: string; + urlTemplate: string; } export interface EditorRetrieveResponse { /** * editor contains the editor */ - editor?: Editor; + editor: Editor; } export interface EditorResolveURLResponse { /** * url is the resolved editor URL */ - url?: string; + url: string; } export interface EditorRetrieveParams { /** * id is the ID of the editor to get */ - id?: string; + id: string; } export interface EditorListParams extends EditorsPageParams { @@ -103,17 +103,17 @@ export interface EditorResolveURLParams { /** * editorId is the ID of the editor to resolve the URL for */ - editorId?: string; + editorId: string; /** * environmentId is the ID of the environment to resolve the URL for */ - environmentId?: string; + environmentId: string; /** * organizationId is the ID of the organization to resolve the URL for */ - organizationId?: string; + organizationId: string; } export declare namespace Editors { diff --git a/tests/api-resources/editors.test.ts b/tests/api-resources/editors.test.ts index 34f291e..a74c114 100644 --- a/tests/api-resources/editors.test.ts +++ b/tests/api-resources/editors.test.ts @@ -9,8 +9,8 @@ const client = new Gitpod({ describe('resource editors', () => { // skipped: tests are disabled for the time being - test.skip('retrieve', async () => { - const responsePromise = client.editors.retrieve({}); + test.skip('retrieve: only required params', async () => { + const responsePromise = client.editors.retrieve({ id: 'id' }); const rawResponse = await responsePromise.asResponse(); expect(rawResponse).toBeInstanceOf(Response); const response = await responsePromise; @@ -20,6 +20,11 @@ describe('resource editors', () => { expect(dataAndResponse.response).toBe(rawResponse); }); + // skipped: tests are disabled for the time being + test.skip('retrieve: required and optional params', async () => { + const response = await client.editors.retrieve({ id: 'id' }); + }); + // skipped: tests are disabled for the time being test.skip('list', async () => { const responsePromise = client.editors.list({}); @@ -33,8 +38,12 @@ describe('resource editors', () => { }); // skipped: tests are disabled for the time being - test.skip('resolveURL', async () => { - const responsePromise = client.editors.resolveURL({}); + test.skip('resolveURL: only required params', async () => { + const responsePromise = client.editors.resolveURL({ + editorId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + environmentId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + organizationId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + }); const rawResponse = await responsePromise.asResponse(); expect(rawResponse).toBeInstanceOf(Response); const response = await responsePromise; @@ -43,4 +52,13 @@ describe('resource editors', () => { expect(dataAndResponse.data).toBe(response); expect(dataAndResponse.response).toBe(rawResponse); }); + + // skipped: tests are disabled for the time being + test.skip('resolveURL: required and optional params', async () => { + const response = await client.editors.resolveURL({ + editorId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + environmentId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + organizationId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + }); + }); });