Skip to content
PluginStats

@aihubmix/ai-sdk-provider weekly downloads statistics

By aihubmix · npm · AI SDKs

<div align="center"> <a href="README.md">🇺🇸 English</a> | <a href="README.zh.md">🇨🇳 中文</a> | <a href="README.ja.md">🇯🇵 日本語</a> </div>

View on npm Stale · Oct 18, 2026

@aihubmix/ai-sdk-provider has 20,832 recorded weekly downloads on npm, a decrease of 5.1% over the past 30 days, ranking #778 of 2,391 tracked listings.

Weekly downloads
20,832
Official API · Oct 18, 2026
7-day growth
-38.4%
-13K weekly downloads
30-day growth
-5.1%
-1.1K weekly downloads
90-day growth
+54.1%
+7.3K weekly downloads
Rank
#778
Among tracked npm listings

About @aihubmix/ai-sdk-provider

AI SDK - Aihubmix Provider

<div align="center"> <a href="README.md">🇺🇸 English</a> | <a href="README.zh.md">🇨🇳 中文</a> | <a href="README.ja.md">🇯🇵 日本語</a> </div>

🎉 10% discount! Built-in app-code; using this method to request all models offers a 10% discount.

Aihubmix Official Website | Model Square

The Aihubmix provider for the AI SDK One Gateway, Infinite Models;one-stop request: OpenAI, Claude, Gemini, DeepSeek, Qwen, and over 500 AI models.

Setup for AI SDK v6

npm i @aihubmix/ai-sdk-provider
(LEGACY) Setup for AI SDK v5
npm i @aihubmix/ai-sdk-provider@0.0.6

Supported Features

The Aihubmix provider supports the following AI features:

  • Text Generation: Chat completion with various models
  • Streaming Text: Real-time text streaming
  • Image Generation: Create images from text prompts
  • Embeddings: Single and batch text embeddings
  • Object Generation: Structured data generation with schemas
  • Streaming Objects: Real-time structured data streaming
  • Speech Synthesis: Text-to-speech conversion
  • Transcription: Speech-to-text conversion
  • Tools: Web search and other tools

Provider Instance

You can import the default provider instance aihubmix from @aihubmix/ai-sdk-provider:

import { aihubmix } from '@aihubmix/ai-sdk-provider';

Configuration

Set your Aihubmix API key as an environment variable:

export AIHUBMIX_API_KEY="your-api-key-here"

Or pass it directly to the provider:

import { createAihubmix } from '@aihubmix/ai-sdk-provider';

const aihubmix = createAihubmix({
  apiKey: 'your-api-key-here',
});
appCode (optional)

Every request carries an APP-Code header. By default it uses the value built into this package, so you do not need to set it. If you have your own app code, pass appCode to override the default:

import { createAihubmix } from '@aihubmix/ai-sdk-provider';

const aihubmix = createAihubmix({
  apiKey: 'your-api-key-here',
  appCode: 'YOUR-APP-CODE', // optional; falls back to the built-in default when omitted
});
baseURL (optional)

By default all requests go to https://aihubmix.com. To route through your own gateway or proxy, pass baseURL (a trailing slash is allowed and stripped). Paths such as /v1 and /gemini/v1beta are appended automatically:

import { createAihubmix } from '@aihubmix/ai-sdk-provider';

const aihubmix = createAihubmix({
  apiKey: 'your-api-key-here',
  baseURL: 'https://your-gateway.example.com', // optional; defaults to https://aihubmix.com
});
Custom fetch

You may pass a custom fetch implementation (for proxies, logging, or testing). It is forwarded to every model — OpenAI-compatible, Claude, Gemini, Responses, transcription, and speech:

const aihubmix = createAihubmix({
  apiKey: 'your-api-key-here',
  fetch: myCustomFetch,
});

Usage

First, import the necessary functions:

import { createAihubmix } from '@aihubmix/ai-sdk-provider';
import { 
  generateText, 
  streamText, 
  experimental_generateImage as generateImage, 
  embed, 
  embedMany, 
  generateObject, 
  streamObject, 
  experimental_generateSpeech as generateSpeech, 
  experimental_transcribe as transcribe 
} from 'ai';
import { z } from 'zod';

Note: Some APIs like generateImage, generateSpeech, and transcribe are still experimental in AI SDK v6.

Generate Text
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { generateText } from 'ai';

const { text } = await generateText({
  model: aihubmix('o4-mini'),
  prompt: 'Write a vegetarian lasagna recipe for 4 people.',
});
Claude Model
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { generateText } from 'ai';

const { text } = await generateText({
  model: aihubmix('claude-3-7-sonnet-20250219'),
  prompt: 'Explain quantum computing in simple terms.',
});
Gemini Model
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { generateText } from 'ai';

const { text } = await generateText({
  model: aihubmix('gemini-2.5-flash'),
  prompt: 'Create a Python script to sort a list of numbers.',
});
Image Generation
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { generateImage } from 'ai';

const { image } = await generateImage({
  model: aihubmix.image('gpt-image-1'),
  prompt: 'A beautiful sunset over mountains',
});
Embeddings
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { embed } from 'ai';

const { embedding } = await embed({
  model: aihubmix.embedding('text-embedding-ada-002'),
  value: 'Hello, world!',
});
Transcription
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { transcribe } from 'ai';

const { text } = await transcribe({
  model: aihubmix.transcription('whisper-1'),
  audio: audioFile,
});
Stream Text
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { streamText } from 'ai';

const result = streamText({
  model: aihubmix('gpt-3.5-turbo'),
  prompt: 'Write a short story about a robot learning to paint.',
  maxOutputTokens: 256,
  temperature: 0.3,
  maxRetries: 3,
});

let fullText = '';
for await (const textPart of result.textStream) {
  fullText += textPart;
  process.stdout.write(textPart);
}

console.log('\nUsage:', await result.usage);
console.log('Finish reason:', await result.finishReason);
Generate Object
import { aihubmix } from '@aihubmix/ai-sdk-provider';
import { generateObject } from 'ai';
import { z } from 'zod';…

Description from the npm listing.

  • ai
  • aihubmix
  • ai-sdk-provider
  • ai-sdk

README badge

Show your rank in a README or on your website. The badge updates automatically.

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

@aihubmix/ai-sdk-provider weekly downloads on npm, last 90 days: 20,832 weekly downloads as of Oct 18, 2026, +54.1% over 90 days.@aihubmix/ai-sdk-providerWeekly downloads on npm · Last 90 days20,832downloads / week+54.1% over 90 days010K20K30K40K50K60KJul 20Aug 4Aug 19Sep 3Sep 18Oct 3Oct 18downloads / weekobservedarchived (Internet Archive)no observationsJul 24, 2026 – Oct 18, 2026 · 87 observations · Updated Oc…pluginstats.com
@aihubmix/ai-sdk-provider weekly downloads on npm, last 90 days: 20,832 weekly downloads as of Oct 18, 2026, +54.1% over 90 days.

7/30/90-day growth

@aihubmix/ai-sdk-provider weekly downloads growth on npm: -38.4% over 7 days, -5.1% over 30 days, +54.1% over 90 days.@aihubmix/ai-sdk-providerWeekly downloads growth on npm20,832downloads / week now7-day growth-12,981 weekly downloads-38.4%30-day growth-1,130 weekly downloads-5.1%90-day growth+7,316 weekly downloads+54.1%Growth vs. nearest observation to each baseline date · Updated Oct 18, 2026pluginstats.com
@aihubmix/ai-sdk-provider weekly downloads growth on npm: -38.4% over 7 days, -5.1% over 30 days, +54.1% over 90 days.

Ranking history

@aihubmix/ai-sdk-provider npm ranking history: currently #778 (by weekly downloads).@aihubmix/ai-sdk-providernpm ranking · by weekly downloads · Last 90 days#778current rank#200#300#400#500#600#700#800Jul 23Aug 7Aug 22Sep 6Sep 21Oct 6Oct 21rankOct 17, 2026 – Oct 21, 2026 · 5 observations · Updated Oct 18, 2026pluginstats.com
@aihubmix/ai-sdk-provider npm ranking history: currently #778 (by weekly downloads).

Listing placement

All npm2,389 listings · 120 pages · 1,196 shown · page 40, #2 (overall #782)
All npm: every listing in weekly downloads order

Listing placement

AI SDKs264 listings · 14 pages · page 3, #7 (overall #47)
AI SDKs: every listing in weekly downloads order

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

Recent observations

Full history (544)
Recent weekly downloads observations for @aihubmix/ai-sdk-provider
Date (UTC)Weekly downloadsChange vs. previous
20,832+3.4K
17,385-3.2K
20,612+670
19,942-5.7K
25,673-5.2K
30,8430
30,843-3K
33,813-5.4K
39,175-1.7K
40,874-1.4K
42,257-4.7K
46,931-2.4K
49,305-7.7K
57,000—

Data source

Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.

Listing: https://www.npmjs.com/package/@aihubmix/ai-sdk-provider. First seen Oct 16, 2026; last successful collection Oct 21, 2026. See the methodology.