npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

fashio-client

v0.1.0

Published

Official JavaScript/TypeScript SDK for the Fashio API — generate on-model fashion photos and video from your own code.

Readme

fashio-client

Official JavaScript/TypeScript SDK for the Fashio API — generate on-model e-commerce fashion photos and video from your own code.

Fashio turns a garment or product photo into publish-ready photography and video with AI: virtual try-on, catalog packs, background removal, upscaling, reframing, and more — the same pipeline behind the Fashio app and dashboard, exposed as a public v1 REST API. This package is a thin, typed wrapper around that API — no local business logic, one method per endpoint.

Prefer to let an AI agent call it directly? See fashio-mcp. Prefer the command line? See fashio-cli.

Install

npm install fashio-client

Usage

import { Fashio } from "fashio-client";

const fashio = new Fashio(process.env.FASHIO_API_KEY!);

// Start a virtual try-on generation
const job = await fashio.createGeneration({
  toolId: "virtual_model",
  images: {
    fashion_model: "fm_south_asian_01",
    garment_photo: "https://your-cdn.com/dress.jpg",
  },
});

// Poll until it's done
let result = job;
while (result.status === "processing") {
  await new Promise((r) => setTimeout(r, 2000));
  result = await fashio.getGeneration(job.id);
}
console.log(result.resultUrls);

Get a free key at fashiolabs.com → Profile → API Keys.

API

| Method | Endpoint | |---|---| | listModels() | GET /v1/models | | listFashionModels({ gender?, limit? }) | GET /v1/fashion-models | | listVenues({ limit? }) | GET /v1/venues | | listPoses({ type?, limit? }) | GET /v1/poses | | uploadImage(bytes, contentType) | POST /v1/uploads | | createGeneration(body) | POST /v1/generations | | getGeneration(id) | GET /v1/generations/:id | | getAccount() | GET /v1/account | | createTemplateSet(body) | POST /v1/template-sets | | listTemplateSets() | GET /v1/template-sets | | deleteTemplateSet(id) | DELETE /v1/template-sets/:id | | listReadyTemplateSets(params) | GET /v1/ready-template-sets | | getReadyTemplateSet(id) | GET /v1/ready-template-sets/:id | | createCatalogJob(body) | POST /v1/catalog-jobs |

Full request/response shapes, per-tool required fields, and error codes: docs.fashiolabs.com.

Errors

Non-2xx responses throw FashioApiError (.status, .message):

import { Fashio, FashioApiError } from "fashio-client";

try {
  await fashio.createGeneration({ toolId: "virtual_model" });
} catch (e) {
  if (e instanceof FashioApiError && e.status === 402) {
    console.log("Out of credits:", e.message);
  }
}

Links

License

MIT — see LICENSE.