# @bitgo-beta/statics

> dependency-free static configuration for the bitgo platform

Latest version **7.0.0** (published 2022-09-29) · Apache-2.0 license · 122.3K weekly downloads

## Install

```sh
npm install @bitgo-beta/statics
pnpm add @bitgo-beta/statics
yarn add @bitgo-beta/statics
bun add @bitgo-beta/statics
```

## Health

**Score 55/100 (C)** — status: abandoned.

Positive: moderate downloads; has types; no vulnerabilities; high maintenance score; high quality score.

Warnings: no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 7.0.0 |
| Published | 2022-09-29 |
| First published | 2022-09-29 |
| Weekly downloads | 122.3K |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 8.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 395 |
| Author | BitGo SDK Team |
| Maintainers | bitgoaaron |

## Links

- npm: https://www.npmjs.com/package/@bitgo-beta/statics
- Repository: https://github.com/BitGo/BitGoJS
- Homepage: https://github.com/BitGo/BitGoJS#readme
- Issues: https://github.com/BitGo/BitGoJS/issues
- npm.io page: https://npm.io/package/@bitgo-beta/statics

## Recent versions

- 7.0.0 (latest) — 2022-09-29
- 15.1.1-beta.2163 (beta) — 2026-10-22
- 10.0.1-alpha.513 (alpha) — 2026-09-29
- 15.1.1-beta.2162 — 2026-10-21
- 15.1.1-beta.2161 — 2026-10-21
- 15.1.1-beta.2160 — 2026-10-21
- 15.1.1-beta.2159 — 2026-10-21
- 15.1.1-beta.2158 — 2026-10-21
- 15.1.1-beta.2157 — 2026-10-21
- 15.1.1-beta.2156 — 2026-10-21
- 15.1.1-beta.2155 — 2026-10-19
- 15.1.1-beta.2154 — 2026-10-19
- 15.1.1-beta.2153 — 2026-10-17
- 15.1.1-beta.2152 — 2026-10-17
- 15.1.1-beta.2151 — 2026-10-17
- … 2905 more at https://npm.io/package/@bitgo-beta/statics/versions

## README

<h1 style="text-align: center;">
  <pre>@bitgo/statics</pre>
</h1>
<h3 style="text-align: center;">
  Static config for the BitGo platform
</h3>

## Goals

- Provide an "encyclopedia" of all relevant constants which are sprinkled throughout the BitGo stack.
- Separate _static_ config data from _dynamic_ config data
- Strong typing for static config properties, with full type information for configuration items
- Ability to export static configuration as JSON for consumption by non-javascript projects

## Examples

### Get the number of decimal places in a Bitcoin

#### JavaScript

```js
const { coins } = require('@bitgo/statics');

const btc = coins.get('btc');
console.log(btc.decimalPlaces);
```

#### TypeScript

```typescript
import { coins } from '@bitgo/statics';

const btc = coins.get('btc');
console.log(btc.decimalPlaces);
```

### Get the contract address for the OmiseGo ERC20 Token

#### JavaScript

```js
const { coins } = require('@bitgo/statics');

const omg = coins.get('omg');
console.log(omg.contractAddress);
```

#### TypeScript

```typescript
import { coins, Erc20Coin } from '@bitgo/statics';

const omg = coins.get('omg');
if (omg instanceof Erc20Coin) {
  console.log(omg.contractAddress);
}
```

### List full names of all defined coins

#### JavaScript

```js
const { coins } = require('@bitgo/statics');

coins.forEach((coin) => {
  console.log(coin.fullName);
});
```

#### TypeScript

```typescript
import { coins } from '@bitgo/statics';

coins.forEach((coin) => {
  console.log(coin.fullName);
});
```

## Repo Status

- UTXO and account base types are defined
- Documentation is mostly source code comments and README examples
- This library can be depended on, but expect some changes going forward

## Project Structure

- `src/base.ts`: Interfaces and enums used by coin implementation classes.
- `src/coins.ts`: Coin definitions.
- `src/networks.ts`: Network interfaces and implementation classes.
- `src/utxo.ts`: Unspent Transaction Output (UTXO) based coin classes and factory function.
- `src/account.ts`: Account-based coin classes and factory methods. Includes ERC20 factory functions.
- `src/errors.ts`: Custom Error classes.

## Installation + Building

To install the project locally, run the following steps:

```
$ # clone the project locally
$ git clone git@github.com:BitGo/statics.git

$ # npm install dependencies (optionally use node >8.6.0)
$ # (optionally) nvm install 8.6.0 -- required to run the linter which is executed pre-commit
$ # (optionally) nvm use 8.6.0
$ npm install
```

To build the project (from TypeScript to JavaScript):

```
$ npm run build
```

This builds the JavaScript and adds it to `dist/src/`. You will receive compilation errors if you have invalid syntax.

## Tests

To run tests:

```
$ npm run test
```

---
_Source: https://npm.io/package/@bitgo-beta/statics · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
