Hi i have a question regards the automation API. ...
# automation-api
p
Hi i have a question regards the automation API. about the following function in the Workspace interface:
Copy code
/**
     * Installs a plugin in the Workspace, for example to use cloud providers like AWS or GCP.
     *
     * @param name the name of the plugin.
     * @param version the version of the plugin e.g. "v1.0.0".
     * @param kind the kind of plugin e.g. "resource"
     */
    installPlugin(name: string, version: string, kind?: string): Promise<void>
What is the plugin in this case? Can i compare it to a npm package? So for example a npm dependency in package json: ‘pulumi/aws”: “^5.4.0,’ dependency. What are exactly the use cases for using the function above from the automation API?
l
A plugin is a binary that does CRUD for a particular cloud provider. Your
@pulumi/aws
npm package also needs a binary
pulumi-resource-aws
in order to create cloud resources.
If you are using local programs, plugins will be acquired automatically when you run your program. For inline programs, you need to install the plugins manually before running the stack update.
👍 1