@linode/api-v4
Version:
JavaScript wrapper around the Linode APIv4
51 lines • 2.73 kB
TypeScript
import { Filter, Params, ResourcePage as Page } from '../types';
import { StackScript, StackScriptPayload } from './types';
/**
* Returns a paginated list of StackScripts.
*
*/
export declare const getStackScripts: (params?: Params, filter?: Filter) => Promise<Page<StackScript>>;
/**
* Returns all of the information about a specified StackScript, including the contents of the script.
*
* @param stackscriptId { string } ID of the Image to look up.
*/
export declare const getStackScript: (stackscriptId: number) => Promise<StackScript>;
/**
* Creates a StackScript in your Account.
*
* @param payload { object }
* @param payload.script { string } The script to execute when provisioning a new Linode with this StackScript.
* @param payload.label { string } The StackScript's label is for display purposes only.
* @param payload.images { string[] } An array of Image IDs representing the Images that this StackScript
* is compatible for deploying with.
* @param payload.description { string } A description for the StackScript.
* @param payload.is_public { boolean } This determines whether other users can use your StackScript.
* Once a StackScript is made public, it cannot be made private.
* @param payload.rev_note { string } This field allows you to add notes for the set of revisions
* made to this StackScript.
*/
export declare const createStackScript: (payload: StackScriptPayload) => Promise<StackScript>;
/**
* Updates a StackScript.
*
* @param stackscriptId { string } The ID of the StackScript to update.
* @param payload { object }
* @param payload.script { string } The script to execute when provisioning a new Linode with this StackScript.
* @param payload.label { string } The StackScript's label is for display purposes only.
* @param payload.images { string[] } An array of Image IDs representing the Images that this StackScript
* is compatible for deploying with.
* @param payload.description { string } A description for the StackScript.
* @param payload.is_public { boolean } This determines whether other users can use your StackScript.
* Once a StackScript is made public, it cannot be made private.
* @param payload.rev_note { string } This field allows you to add notes for the set of revisions
* made to this StackScript.
*/
export declare const updateStackScript: (stackscriptId: number, payload: Partial<StackScriptPayload>) => Promise<StackScript>;
/**
* Deletes a private StackScript you have permission to read_write. You cannot delete a public StackScript.
*
* @param stackscriptId { string } The ID of the StackScript to delete.
*/
export declare const deleteStackScript: (stackscriptId: number) => Promise<{}>;
//# sourceMappingURL=stackscripts.d.ts.map