Skip to content

Commit

Permalink
Generate types for script.packages
Browse files Browse the repository at this point in the history
  • Loading branch information
coditva committed Feb 23, 2024
1 parent 6b55bcf commit 81c4174
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2142,6 +2142,13 @@ declare module "postman-collection" {
static createFromNode(response: any, cookies: any): any;
}

/**
* A map of package names to the IDs of the packages
*/
export type Packages = {
[key: string]: { id: string; };
};

/**
* Postman scripts that are executed upon events on a collection / request such as test and pre request.
* @param options - -
Expand All @@ -2158,13 +2165,19 @@ declare module "postman-collection" {
* @param [options.type] - Script type
* @param [options.src] - Script source url
* @param [options.exec] - Script to execute
* @param [options.packages] - Packages required by the script
*/
update(options?: {
type?: string;
src?: string;
exec?: string[] | string;
packages?: Packages;
}): void;
type: string;
/**
* The packages required by the script
*/
packages: Packages;
src: Url;
exec: string[];
/**
Expand Down

0 comments on commit 81c4174

Please sign in to comment.