1.0.0 • Published 8 months ago

node-mirai v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

node-mirai

Package for m1r.ai

Installation

pnpm add node-mirai

Example

import { upload } from 'node-mirai'

const { url } = await upload(
  './path/to/file.png', 
  { 
    headers: { 
      Random: 'test-image', 
      CustomHeader: 'test' 
    } 
  }
)

console.log(url)

Config

upload

file

Accept type File Blob string, can be stream of file or path to the file

options

Optional, mostly alias from node fetch() options with additional upload options

1.0.0

8 months ago