diff --git a/types/ThinEvent.d.ts b/types/ThinEvent.d.ts index d1feb07c34..269ed2057a 100644 --- a/types/ThinEvent.d.ts +++ b/types/ThinEvent.d.ts @@ -3,26 +3,24 @@ declare module 'stripe' { namespace Stripe { namespace Event { + /** + * Object containing the reference to API resource relevant to the event. + */ interface RelatedObject { /** - * Object containing the reference to API resource relevant to the event. + * Unique identifier for the object relevant to the event. */ - related_object: { - /** - * Unique identifier for the object relevant to the event. - */ - id: string; + id: string; - /** - * Type of the object relevant to the event. - */ - type: string; + /** + * Type of the object relevant to the event. + */ + type: string; - /** - * URL to retrieve the resource. - */ - url: string; - }; + /** + * URL to retrieve the resource. + */ + url: string; } } /** @@ -32,7 +30,7 @@ declare module 'stripe' { /** * Object containing the reference to API resource relevant to the event. */ - related_object: Event.RelatedObject; + related_object: Event.RelatedObject | null; } } } diff --git a/types/V2/Core/EventsResource.d.ts b/types/V2/Core/EventsResource.d.ts index e74b6bee42..a37355274f 100644 --- a/types/V2/Core/EventsResource.d.ts +++ b/types/V2/Core/EventsResource.d.ts @@ -1,5 +1,7 @@ // File generated from our OpenAPI spec +/// + declare module 'stripe' { namespace Stripe { namespace V2 { @@ -29,11 +31,11 @@ declare module 'stripe' { id: string, params?: EventRetrieveParams, options?: RequestOptions - ): Promise>; + ): Promise>; retrieve( id: string, options?: RequestOptions - ): Promise>; + ): Promise>; /** * List events, going back up to 30 days. @@ -41,7 +43,7 @@ declare module 'stripe' { list( params: EventListParams, options?: RequestOptions - ): ApiListPromise; + ): ApiListPromise; } } }