diff --git a/README.md b/README.md index c201bcb..8a01335 100644 --- a/README.md +++ b/README.md @@ -22,5 +22,16 @@ BING_IMAGE_COOKIE: ### Import the package ``` -import bimg from 'bimg'; +import { generateImageFiles, generateImagesLinks } from "bimg"; + +const imageLinks = await generateImagesLinks(prompt); // returns an array of 4 image links +const imageFiles = await generateImageFiles(prompt); // returns an array of 4 image files +``` + +The image file is a object of ``` +{ + name: string, + data: string // base64 encoded image data from Buffer +} +``` \ No newline at end of file diff --git a/package.json b/package.json index 01553df..005e695 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bimg", - "version": "0.1.0", + "version": "0.1.1", "description": "A reverse-engineered Bing Image Creation API", "main": "dist/index.js", "type": "module", diff --git a/src/index.ts b/src/index.ts index 6f118a0..b837451 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,2 +1,2 @@ -export * from "./imgen"; -export * from "./config"; +export * from "./imgen.js"; +export * from "./config.js";