@habbzy/origins-api
TypeScript icon, indicating that this package has built-in type declarations

2.0.2 • Public • Published
Habbzy Logo
NPM Discord GPL-3.0-only

TypeScript bindings for the Habbo Origins API

Why? Well, at Habbzy we need to interact with the various public Origins APIs to pull in BattleBall matches, verify Habbo identities and so on. So we're publishing our actively maintained bindings!

  • Fully ESM
  • Actively maintained
  • Zero dependencies
  • TypeScript-first

Installation

npm install @habbzy/origins-api # npm
yarn add @habbzy/origins-api    # yarn
bun add @habbzy/origins-api     # bun
pnpm add @habbzy/origins-api    # pnpm

Usage

Habbo Origins Imager

import { avatarImageUrl } from '@habbzy/origins-api';

const imageUrl = await avatarImageUrl('Evil', {
  size: 'big',
  direction: 'sw',
  headDirection: 'sw',
  action: 'stand',
  gesture: 'smile',
});

NOTE: Currently, the figureString from the public Origins API is borked and will return weird color/hat data - I've checked with Macklebee and this is on his to-do list to fix.

Habbo Origins API

import { battleballMatch, avatar } from '@habbzy/origins-api';

const evil = await avatar('Evil');
// evil?.motto

const match = await battleballMatch('gm-hhous-2a66d6af519b206c014284436b4beec3');
// match?.info?.gameCreation

Readme

Keywords

none

Package Sidebar

Install

npm i @habbzy/origins-api

Weekly Downloads

12

Version

2.0.2

License

GPL-3.0-only

Unpacked Size

54.5 kB

Total Files

8

Last publish

Collaborators

  • oyed