### Install Plugin Image Generation Source: https://github.com/elizaos-plugins/plugin-image-generation/blob/main/README.md Installs the plugin-image-generation package using pnpm. ```bash pnpm install plugin-image-generation ``` -------------------------------- ### Plugin Image Generation API Reference Source: https://github.com/elizaos-plugins/plugin-image-generation/blob/main/README.md Provides details on the `generateImage` and `uploadImage` functions available in the plugin. ```APIDOC generateImage Parameters: - width: Width of the image. - height: Height of the image. - backgroundColor: Background color of the image. - text: Text to be displayed on the image. - font: Font style for the text. Returns: A promise that resolves with the generated image. uploadImage Parameters: - imagePath: Path to the image file. - bucketName: Name of the storage bucket. Returns: A promise that resolves with the upload result. ``` -------------------------------- ### Upload Image to Storage with Plugin Source: https://github.com/elizaos-plugins/plugin-image-generation/blob/main/README.md Uploads an image to a specified storage bucket using the `uploadImage` function. Requires the image path and bucket name. ```typescript import { uploadImage } from "plugin-image-generation"; const uploadResult = await uploadImage({ imagePath: "path/to/image.png", bucketName: "my-storage-bucket", }); console.log("Image uploaded successfully:", uploadResult); ``` -------------------------------- ### Generate Image with Plugin Source: https://github.com/elizaos-plugins/plugin-image-generation/blob/main/README.md Generates an image dynamically using the `generateImage` function from the plugin. It takes parameters for dimensions, background color, text, and font. ```typescript import { generateImage } from "plugin-image-generation"; const image = await generateImage({ width: 800, height: 600, backgroundColor: "#ffffff", text: "Hello World", font: "Arial", }); console.log("Generated Image:", image); ``` -------------------------------- ### TypeScript Configuration for Plugin Image Generation Source: https://github.com/elizaos-plugins/plugin-image-generation/blob/main/README.md Specifies the necessary TypeScript compiler options for the plugin, including module resolution and strictness. ```json { "compilerOptions": { "module": "ESNext", "target": "ES6", "moduleResolution": "node", "strict": true } } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.