@oikos/core-addresses 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +157 -0
- package/dist/cli.cjs +157 -0
- package/dist/cli.d.cts +1 -0
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +156 -0
- package/dist/index.cjs +153 -0
- package/dist/index.d.cts +31 -0
- package/dist/index.d.ts +31 -0
- package/dist/index.js +115 -0
- package/package.json +68 -0
package/README.md
ADDED
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
# @oikos/core-addresses
|
|
2
|
+
|
|
3
|
+
Programmatic access to Oikos Protocol contract addresses by chain id or network name.
|
|
4
|
+
|
|
5
|
+
Deployment data is bundled from a pinned release tag of [`oikos-cash/core`](https://github.com/oikos-cash/core), so installing a fixed version of this package gives you a frozen, offline snapshot of the addresses for that protocol release.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```sh
|
|
10
|
+
npm install @oikos/core-addresses
|
|
11
|
+
# or
|
|
12
|
+
pnpm add @oikos/core-addresses
|
|
13
|
+
# or
|
|
14
|
+
yarn add @oikos/core-addresses
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Programmatic usage
|
|
18
|
+
|
|
19
|
+
```ts
|
|
20
|
+
import {
|
|
21
|
+
getAddress,
|
|
22
|
+
getAddresses,
|
|
23
|
+
getSupportedNetworks,
|
|
24
|
+
isSupported,
|
|
25
|
+
SOURCE_TAG,
|
|
26
|
+
} from "@oikos/core-addresses";
|
|
27
|
+
|
|
28
|
+
// By chain id
|
|
29
|
+
const vault = getAddress(56, "Vault");
|
|
30
|
+
|
|
31
|
+
// By name or alias (case-insensitive: bsc, bnb, binance, bnbchain, ...)
|
|
32
|
+
const pool = getAddress("bsc", "Pool");
|
|
33
|
+
|
|
34
|
+
// Full address map for a network
|
|
35
|
+
const addrs = getAddresses("bnb");
|
|
36
|
+
// {
|
|
37
|
+
// Vault: "0x...",
|
|
38
|
+
// Pool: "0x...",
|
|
39
|
+
// ...
|
|
40
|
+
// }
|
|
41
|
+
|
|
42
|
+
isSupported(56); // true
|
|
43
|
+
isSupported(1); // false
|
|
44
|
+
SOURCE_TAG; // "v0.1" — pinned protocol release
|
|
45
|
+
getSupportedNetworks();
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
CommonJS also works:
|
|
49
|
+
|
|
50
|
+
```js
|
|
51
|
+
const { getAddress } = require("@oikos/core-addresses");
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### API
|
|
55
|
+
|
|
56
|
+
| Export | Description |
|
|
57
|
+
| --- | --- |
|
|
58
|
+
| `getAddresses(network)` | Returns a copy of the full `{ contract: address }` map for the network. Throws if unknown. |
|
|
59
|
+
| `getAddress(network, contract)` | Returns a single address. Throws if the network or contract is unknown. |
|
|
60
|
+
| `isSupported(network)` | `true` if the network has a bundled deployment. |
|
|
61
|
+
| `getSupportedNetworks()` | List of `{ chainId, name, aliases }` for networks with deployments. |
|
|
62
|
+
| `getNetworkInfo(network)` | Resolves any identifier to its `NetworkInfo`, or `undefined`. |
|
|
63
|
+
| `deployment` | Raw `{ chainId: { contract: address } }` map. |
|
|
64
|
+
| `NETWORKS` | All known network metadata (including networks without deployments yet). |
|
|
65
|
+
| `getSourceMeta()` | `{ tag, source, fetchedAt, sha256 }` for the bundled snapshot. |
|
|
66
|
+
| `SOURCE_TAG` / `SOURCE_URL` / `FETCHED_AT` / `SOURCE_SHA256` | Same values as above, as top-level constants. |
|
|
67
|
+
|
|
68
|
+
`network` can be a number (`56`), a numeric string (`"56"`), the canonical name (`"bsc"`), or any registered alias (`"bnb"`, `"binance"`, `"bnbchain"`, `"bsc-mainnet"`, `"bnb-mainnet"`). Names are case-insensitive.
|
|
69
|
+
|
|
70
|
+
### Types
|
|
71
|
+
|
|
72
|
+
```ts
|
|
73
|
+
type NetworkInfo = {
|
|
74
|
+
chainId: number;
|
|
75
|
+
name: string;
|
|
76
|
+
aliases: readonly string[];
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
type ContractAddresses = Record<string, string>;
|
|
80
|
+
type Deployment = Record<string, ContractAddresses>;
|
|
81
|
+
|
|
82
|
+
type SourceMeta = {
|
|
83
|
+
tag: string; // e.g. "v0.1"
|
|
84
|
+
source: string; // raw.githubusercontent URL the data was fetched from
|
|
85
|
+
fetchedAt: string; // ISO-8601 timestamp
|
|
86
|
+
sha256: string; // sha256 of the fetched bytes
|
|
87
|
+
};
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## CLI (`npx`)
|
|
91
|
+
|
|
92
|
+
```sh
|
|
93
|
+
npx @oikos/core-addresses 56
|
|
94
|
+
npx @oikos/core-addresses bsc
|
|
95
|
+
npx @oikos/core-addresses bsc Vault
|
|
96
|
+
npx @oikos/core-addresses --list
|
|
97
|
+
npx @oikos/core-addresses --json bsc
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
| Flag | Effect |
|
|
101
|
+
| --- | --- |
|
|
102
|
+
| `-h, --help` | Show usage. |
|
|
103
|
+
| `-l, --list` | List supported networks plus the bundled source tag and sha256. |
|
|
104
|
+
| `-j, --json` | Print compact single-line JSON instead of pretty-printed. |
|
|
105
|
+
|
|
106
|
+
Exit code is `1` on unknown network or unknown contract.
|
|
107
|
+
|
|
108
|
+
## Supported networks
|
|
109
|
+
|
|
110
|
+
| chainId | name | aliases |
|
|
111
|
+
| --- | --- | --- |
|
|
112
|
+
| 56 | `bsc` | `bnb`, `binance`, `bnbchain`, `bsc-mainnet`, `bnb-mainnet` |
|
|
113
|
+
|
|
114
|
+
Adding a new network: append an entry to [`src/networks.ts`](src/networks.ts) and make sure the chain id is present in the source `deployment.json`.
|
|
115
|
+
|
|
116
|
+
## How the deployment data is pinned
|
|
117
|
+
|
|
118
|
+
This package does not check its address data into git. Instead, on every build it fetches the canonical `deployment.json` from a pinned ref of `oikos-cash/core`:
|
|
119
|
+
|
|
120
|
+
```
|
|
121
|
+
https://raw.githubusercontent.com/oikos-cash/core/${oikosCoreTag}/deploy_helper/out/deployment.json
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
The fetched bytes (plus tag, URL, timestamp, and sha256) are bundled into `dist/` and re-exported from the library, so consumers can verify which protocol release they are running against.
|
|
125
|
+
|
|
126
|
+
- The pin lives in [`package.json`](package.json) under `"oikosCoreTag"` (default `v0.1`).
|
|
127
|
+
- It can be overridden ad-hoc via the `OIKOS_CORE_TAG` env var or a positional arg to the fetch script.
|
|
128
|
+
- Network access is required at **build/publish time only**. End consumers installing from npm get a fully bundled, offline-capable package.
|
|
129
|
+
|
|
130
|
+
### Bumping the pinned protocol release
|
|
131
|
+
|
|
132
|
+
1. Edit `oikosCoreTag` in `package.json` to the new tag (e.g. `v0.2`).
|
|
133
|
+
2. Bump the npm `version` in `package.json` to match.
|
|
134
|
+
3. `npm run build` — re-fetches from the new ref and re-bundles.
|
|
135
|
+
4. `npm publish --access public`.
|
|
136
|
+
|
|
137
|
+
Or as a one-off without changing the default:
|
|
138
|
+
|
|
139
|
+
```sh
|
|
140
|
+
OIKOS_CORE_TAG=v0.2 npm run build
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
## Development
|
|
144
|
+
|
|
145
|
+
```sh
|
|
146
|
+
npm install
|
|
147
|
+
npm run fetch-deployment # writes data/deployment.json + data/meta.json
|
|
148
|
+
npm run build # tsup → dist/{index,cli}.{js,cjs,d.ts,d.cts}
|
|
149
|
+
npm test # node:test against the built bundle
|
|
150
|
+
npm run typecheck # tsc --noEmit
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
`npm install` runs `prepare`, which runs the fetch + build pipeline automatically, so a fresh clone is ready to use immediately (network is required on first install in order to fetch the pinned deployment data).
|
|
154
|
+
|
|
155
|
+
## License
|
|
156
|
+
|
|
157
|
+
MIT.
|
package/dist/cli.cjs
ADDED
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";
|
|
3
|
+
|
|
4
|
+
// data/deployment.json
|
|
5
|
+
var deployment_default = {
|
|
6
|
+
"56": {
|
|
7
|
+
Vault: "0x6D77a715d2047a69DFdf922876712c4ef17d1788",
|
|
8
|
+
Pool: "0x104bab30b2983df47dd504114353B0A73bF663CE",
|
|
9
|
+
Proxy: "0x614da16Af43A8Ad0b9F419Ab78d14D163DEa6488",
|
|
10
|
+
ExchangeHelper: "0xe9490B6AA9e3847636CD491f9962Ab2658E589F6",
|
|
11
|
+
ModelHelper: "0x0b94E3c636C967e1e169faeb268C2ca741E9987A",
|
|
12
|
+
AdaptiveSupply: "0xd0581Ba58A5970F83ac1F2f23be09202db96303d",
|
|
13
|
+
RewardsCalculator: "0x88F83ab63ccf9129Cbb681145F879790d29cC4e6",
|
|
14
|
+
Resolver: "0xa78142B2A829AbA5D737af86a14d2BeEE82dDcF9",
|
|
15
|
+
Factory: "0x9F5973EC7E5f0781E0fCE71Dd949c997c38508Fc"
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
// data/meta.json
|
|
20
|
+
var meta_default = {
|
|
21
|
+
tag: "v0.1",
|
|
22
|
+
source: "https://raw.githubusercontent.com/oikos-cash/core/v0.1/deploy_helper/out/deployment.json",
|
|
23
|
+
fetchedAt: "2026-05-16T19:38:51.457Z",
|
|
24
|
+
sha256: "5e593341d02a2e9f935d0b234401090c6e858a654fed307ad3ccef83d6fedbb7"
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
// src/networks.ts
|
|
28
|
+
var NETWORKS = [
|
|
29
|
+
{
|
|
30
|
+
chainId: 56,
|
|
31
|
+
name: "bsc",
|
|
32
|
+
aliases: ["bsc", "bnb", "binance", "bnbchain", "bsc-mainnet", "bnb-mainnet"]
|
|
33
|
+
}
|
|
34
|
+
];
|
|
35
|
+
|
|
36
|
+
// src/index.ts
|
|
37
|
+
var deployment = deployment_default;
|
|
38
|
+
var meta = meta_default;
|
|
39
|
+
var SOURCE_TAG = meta.tag;
|
|
40
|
+
var SOURCE_URL = meta.source;
|
|
41
|
+
var FETCHED_AT = meta.fetchedAt;
|
|
42
|
+
var SOURCE_SHA256 = meta.sha256;
|
|
43
|
+
function resolveChainId(network) {
|
|
44
|
+
if (typeof network === "number") {
|
|
45
|
+
if (!Number.isFinite(network) || !Number.isInteger(network)) {
|
|
46
|
+
throw new Error(`Invalid chain id: ${network}`);
|
|
47
|
+
}
|
|
48
|
+
return network;
|
|
49
|
+
}
|
|
50
|
+
const s = String(network).toLowerCase().trim();
|
|
51
|
+
if (s === "") throw new Error("Network identifier is empty");
|
|
52
|
+
if (/^\d+$/.test(s)) return Number.parseInt(s, 10);
|
|
53
|
+
const match = NETWORKS.find(
|
|
54
|
+
(n) => n.name === s || n.aliases.includes(s)
|
|
55
|
+
);
|
|
56
|
+
if (!match) {
|
|
57
|
+
const known = NETWORKS.map((n) => `${n.chainId} (${n.name})`).join(", ");
|
|
58
|
+
throw new Error(`Unknown network: "${network}". Known: ${known}`);
|
|
59
|
+
}
|
|
60
|
+
return match.chainId;
|
|
61
|
+
}
|
|
62
|
+
function getAddresses(network) {
|
|
63
|
+
const chainId = resolveChainId(network);
|
|
64
|
+
const addrs = deployment[String(chainId)];
|
|
65
|
+
if (!addrs) {
|
|
66
|
+
throw new Error(`No deployment found for chain id ${chainId}`);
|
|
67
|
+
}
|
|
68
|
+
return { ...addrs };
|
|
69
|
+
}
|
|
70
|
+
function getAddress(network, contract) {
|
|
71
|
+
const addrs = getAddresses(network);
|
|
72
|
+
const addr = addrs[contract];
|
|
73
|
+
if (!addr) {
|
|
74
|
+
throw new Error(
|
|
75
|
+
`Contract "${contract}" not deployed on network ${network}`
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
return addr;
|
|
79
|
+
}
|
|
80
|
+
function getSupportedNetworks() {
|
|
81
|
+
return NETWORKS.filter(
|
|
82
|
+
(n) => deployment[String(n.chainId)] !== void 0
|
|
83
|
+
).map((n) => ({ ...n, aliases: [...n.aliases] }));
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// src/cli.ts
|
|
87
|
+
var HELP = `Usage: oikos-addresses <network> [contract]
|
|
88
|
+
|
|
89
|
+
Print Oikos Protocol contract addresses for a given network.
|
|
90
|
+
|
|
91
|
+
Arguments:
|
|
92
|
+
network Chain id (e.g. 56) or network name (e.g. bsc, bnb, binance)
|
|
93
|
+
contract Optional contract name (e.g. Vault). If omitted, prints all.
|
|
94
|
+
|
|
95
|
+
Examples:
|
|
96
|
+
oikos-addresses 56
|
|
97
|
+
oikos-addresses bsc
|
|
98
|
+
oikos-addresses bsc Vault
|
|
99
|
+
oikos-addresses --list
|
|
100
|
+
oikos-addresses --json bsc
|
|
101
|
+
|
|
102
|
+
Options:
|
|
103
|
+
-h, --help Show this help
|
|
104
|
+
-l, --list List supported networks
|
|
105
|
+
-j, --json Output a single-line JSON (default is pretty-printed JSON)
|
|
106
|
+
`;
|
|
107
|
+
function printNetworks() {
|
|
108
|
+
const rows = getSupportedNetworks().map((n) => ({
|
|
109
|
+
chainId: n.chainId,
|
|
110
|
+
name: n.name,
|
|
111
|
+
aliases: n.aliases.join(", ")
|
|
112
|
+
}));
|
|
113
|
+
console.log(`Source: oikos-cash/core @ ${SOURCE_TAG}`);
|
|
114
|
+
console.log(` ${SOURCE_URL}`);
|
|
115
|
+
console.log(` sha256=${SOURCE_SHA256.slice(0, 12)}\u2026 fetchedAt=${FETCHED_AT}`);
|
|
116
|
+
console.log("");
|
|
117
|
+
console.log("Supported networks:");
|
|
118
|
+
for (const r of rows) {
|
|
119
|
+
console.log(` ${r.chainId} ${r.name} [${r.aliases}]`);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
function main(argv) {
|
|
123
|
+
const args = argv.slice(2);
|
|
124
|
+
if (args.length === 0 || args.includes("-h") || args.includes("--help")) {
|
|
125
|
+
process.stdout.write(HELP);
|
|
126
|
+
return 0;
|
|
127
|
+
}
|
|
128
|
+
if (args.includes("-l") || args.includes("--list")) {
|
|
129
|
+
printNetworks();
|
|
130
|
+
return 0;
|
|
131
|
+
}
|
|
132
|
+
const compact = args.includes("-j") || args.includes("--json");
|
|
133
|
+
const positional = args.filter((a) => !a.startsWith("-"));
|
|
134
|
+
const [network, contract] = positional;
|
|
135
|
+
if (!network) {
|
|
136
|
+
process.stderr.write("Error: missing <network>\n\n");
|
|
137
|
+
process.stdout.write(HELP);
|
|
138
|
+
return 1;
|
|
139
|
+
}
|
|
140
|
+
try {
|
|
141
|
+
if (contract) {
|
|
142
|
+
console.log(getAddress(network, contract));
|
|
143
|
+
} else {
|
|
144
|
+
const addrs = getAddresses(network);
|
|
145
|
+
console.log(
|
|
146
|
+
compact ? JSON.stringify(addrs) : JSON.stringify(addrs, null, 2)
|
|
147
|
+
);
|
|
148
|
+
}
|
|
149
|
+
return 0;
|
|
150
|
+
} catch (err) {
|
|
151
|
+
const msg = err instanceof Error ? err.message : String(err);
|
|
152
|
+
process.stderr.write(`Error: ${msg}
|
|
153
|
+
`);
|
|
154
|
+
return 1;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
process.exit(main(process.argv));
|
package/dist/cli.d.cts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
package/dist/cli.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
package/dist/cli.js
ADDED
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
// data/deployment.json
|
|
4
|
+
var deployment_default = {
|
|
5
|
+
"56": {
|
|
6
|
+
Vault: "0x6D77a715d2047a69DFdf922876712c4ef17d1788",
|
|
7
|
+
Pool: "0x104bab30b2983df47dd504114353B0A73bF663CE",
|
|
8
|
+
Proxy: "0x614da16Af43A8Ad0b9F419Ab78d14D163DEa6488",
|
|
9
|
+
ExchangeHelper: "0xe9490B6AA9e3847636CD491f9962Ab2658E589F6",
|
|
10
|
+
ModelHelper: "0x0b94E3c636C967e1e169faeb268C2ca741E9987A",
|
|
11
|
+
AdaptiveSupply: "0xd0581Ba58A5970F83ac1F2f23be09202db96303d",
|
|
12
|
+
RewardsCalculator: "0x88F83ab63ccf9129Cbb681145F879790d29cC4e6",
|
|
13
|
+
Resolver: "0xa78142B2A829AbA5D737af86a14d2BeEE82dDcF9",
|
|
14
|
+
Factory: "0x9F5973EC7E5f0781E0fCE71Dd949c997c38508Fc"
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
// data/meta.json
|
|
19
|
+
var meta_default = {
|
|
20
|
+
tag: "v0.1",
|
|
21
|
+
source: "https://raw.githubusercontent.com/oikos-cash/core/v0.1/deploy_helper/out/deployment.json",
|
|
22
|
+
fetchedAt: "2026-05-16T19:38:51.457Z",
|
|
23
|
+
sha256: "5e593341d02a2e9f935d0b234401090c6e858a654fed307ad3ccef83d6fedbb7"
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
// src/networks.ts
|
|
27
|
+
var NETWORKS = [
|
|
28
|
+
{
|
|
29
|
+
chainId: 56,
|
|
30
|
+
name: "bsc",
|
|
31
|
+
aliases: ["bsc", "bnb", "binance", "bnbchain", "bsc-mainnet", "bnb-mainnet"]
|
|
32
|
+
}
|
|
33
|
+
];
|
|
34
|
+
|
|
35
|
+
// src/index.ts
|
|
36
|
+
var deployment = deployment_default;
|
|
37
|
+
var meta = meta_default;
|
|
38
|
+
var SOURCE_TAG = meta.tag;
|
|
39
|
+
var SOURCE_URL = meta.source;
|
|
40
|
+
var FETCHED_AT = meta.fetchedAt;
|
|
41
|
+
var SOURCE_SHA256 = meta.sha256;
|
|
42
|
+
function resolveChainId(network) {
|
|
43
|
+
if (typeof network === "number") {
|
|
44
|
+
if (!Number.isFinite(network) || !Number.isInteger(network)) {
|
|
45
|
+
throw new Error(`Invalid chain id: ${network}`);
|
|
46
|
+
}
|
|
47
|
+
return network;
|
|
48
|
+
}
|
|
49
|
+
const s = String(network).toLowerCase().trim();
|
|
50
|
+
if (s === "") throw new Error("Network identifier is empty");
|
|
51
|
+
if (/^\d+$/.test(s)) return Number.parseInt(s, 10);
|
|
52
|
+
const match = NETWORKS.find(
|
|
53
|
+
(n) => n.name === s || n.aliases.includes(s)
|
|
54
|
+
);
|
|
55
|
+
if (!match) {
|
|
56
|
+
const known = NETWORKS.map((n) => `${n.chainId} (${n.name})`).join(", ");
|
|
57
|
+
throw new Error(`Unknown network: "${network}". Known: ${known}`);
|
|
58
|
+
}
|
|
59
|
+
return match.chainId;
|
|
60
|
+
}
|
|
61
|
+
function getAddresses(network) {
|
|
62
|
+
const chainId = resolveChainId(network);
|
|
63
|
+
const addrs = deployment[String(chainId)];
|
|
64
|
+
if (!addrs) {
|
|
65
|
+
throw new Error(`No deployment found for chain id ${chainId}`);
|
|
66
|
+
}
|
|
67
|
+
return { ...addrs };
|
|
68
|
+
}
|
|
69
|
+
function getAddress(network, contract) {
|
|
70
|
+
const addrs = getAddresses(network);
|
|
71
|
+
const addr = addrs[contract];
|
|
72
|
+
if (!addr) {
|
|
73
|
+
throw new Error(
|
|
74
|
+
`Contract "${contract}" not deployed on network ${network}`
|
|
75
|
+
);
|
|
76
|
+
}
|
|
77
|
+
return addr;
|
|
78
|
+
}
|
|
79
|
+
function getSupportedNetworks() {
|
|
80
|
+
return NETWORKS.filter(
|
|
81
|
+
(n) => deployment[String(n.chainId)] !== void 0
|
|
82
|
+
).map((n) => ({ ...n, aliases: [...n.aliases] }));
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
// src/cli.ts
|
|
86
|
+
var HELP = `Usage: oikos-addresses <network> [contract]
|
|
87
|
+
|
|
88
|
+
Print Oikos Protocol contract addresses for a given network.
|
|
89
|
+
|
|
90
|
+
Arguments:
|
|
91
|
+
network Chain id (e.g. 56) or network name (e.g. bsc, bnb, binance)
|
|
92
|
+
contract Optional contract name (e.g. Vault). If omitted, prints all.
|
|
93
|
+
|
|
94
|
+
Examples:
|
|
95
|
+
oikos-addresses 56
|
|
96
|
+
oikos-addresses bsc
|
|
97
|
+
oikos-addresses bsc Vault
|
|
98
|
+
oikos-addresses --list
|
|
99
|
+
oikos-addresses --json bsc
|
|
100
|
+
|
|
101
|
+
Options:
|
|
102
|
+
-h, --help Show this help
|
|
103
|
+
-l, --list List supported networks
|
|
104
|
+
-j, --json Output a single-line JSON (default is pretty-printed JSON)
|
|
105
|
+
`;
|
|
106
|
+
function printNetworks() {
|
|
107
|
+
const rows = getSupportedNetworks().map((n) => ({
|
|
108
|
+
chainId: n.chainId,
|
|
109
|
+
name: n.name,
|
|
110
|
+
aliases: n.aliases.join(", ")
|
|
111
|
+
}));
|
|
112
|
+
console.log(`Source: oikos-cash/core @ ${SOURCE_TAG}`);
|
|
113
|
+
console.log(` ${SOURCE_URL}`);
|
|
114
|
+
console.log(` sha256=${SOURCE_SHA256.slice(0, 12)}\u2026 fetchedAt=${FETCHED_AT}`);
|
|
115
|
+
console.log("");
|
|
116
|
+
console.log("Supported networks:");
|
|
117
|
+
for (const r of rows) {
|
|
118
|
+
console.log(` ${r.chainId} ${r.name} [${r.aliases}]`);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
function main(argv) {
|
|
122
|
+
const args = argv.slice(2);
|
|
123
|
+
if (args.length === 0 || args.includes("-h") || args.includes("--help")) {
|
|
124
|
+
process.stdout.write(HELP);
|
|
125
|
+
return 0;
|
|
126
|
+
}
|
|
127
|
+
if (args.includes("-l") || args.includes("--list")) {
|
|
128
|
+
printNetworks();
|
|
129
|
+
return 0;
|
|
130
|
+
}
|
|
131
|
+
const compact = args.includes("-j") || args.includes("--json");
|
|
132
|
+
const positional = args.filter((a) => !a.startsWith("-"));
|
|
133
|
+
const [network, contract] = positional;
|
|
134
|
+
if (!network) {
|
|
135
|
+
process.stderr.write("Error: missing <network>\n\n");
|
|
136
|
+
process.stdout.write(HELP);
|
|
137
|
+
return 1;
|
|
138
|
+
}
|
|
139
|
+
try {
|
|
140
|
+
if (contract) {
|
|
141
|
+
console.log(getAddress(network, contract));
|
|
142
|
+
} else {
|
|
143
|
+
const addrs = getAddresses(network);
|
|
144
|
+
console.log(
|
|
145
|
+
compact ? JSON.stringify(addrs) : JSON.stringify(addrs, null, 2)
|
|
146
|
+
);
|
|
147
|
+
}
|
|
148
|
+
return 0;
|
|
149
|
+
} catch (err) {
|
|
150
|
+
const msg = err instanceof Error ? err.message : String(err);
|
|
151
|
+
process.stderr.write(`Error: ${msg}
|
|
152
|
+
`);
|
|
153
|
+
return 1;
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
process.exit(main(process.argv));
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/index.ts
|
|
21
|
+
var index_exports = {};
|
|
22
|
+
__export(index_exports, {
|
|
23
|
+
FETCHED_AT: () => FETCHED_AT,
|
|
24
|
+
NETWORKS: () => NETWORKS,
|
|
25
|
+
SOURCE_SHA256: () => SOURCE_SHA256,
|
|
26
|
+
SOURCE_TAG: () => SOURCE_TAG,
|
|
27
|
+
SOURCE_URL: () => SOURCE_URL,
|
|
28
|
+
deployment: () => deployment,
|
|
29
|
+
getAddress: () => getAddress,
|
|
30
|
+
getAddresses: () => getAddresses,
|
|
31
|
+
getNetworkInfo: () => getNetworkInfo,
|
|
32
|
+
getSourceMeta: () => getSourceMeta,
|
|
33
|
+
getSupportedNetworks: () => getSupportedNetworks,
|
|
34
|
+
isSupported: () => isSupported
|
|
35
|
+
});
|
|
36
|
+
module.exports = __toCommonJS(index_exports);
|
|
37
|
+
|
|
38
|
+
// data/deployment.json
|
|
39
|
+
var deployment_default = {
|
|
40
|
+
"56": {
|
|
41
|
+
Vault: "0x6D77a715d2047a69DFdf922876712c4ef17d1788",
|
|
42
|
+
Pool: "0x104bab30b2983df47dd504114353B0A73bF663CE",
|
|
43
|
+
Proxy: "0x614da16Af43A8Ad0b9F419Ab78d14D163DEa6488",
|
|
44
|
+
ExchangeHelper: "0xe9490B6AA9e3847636CD491f9962Ab2658E589F6",
|
|
45
|
+
ModelHelper: "0x0b94E3c636C967e1e169faeb268C2ca741E9987A",
|
|
46
|
+
AdaptiveSupply: "0xd0581Ba58A5970F83ac1F2f23be09202db96303d",
|
|
47
|
+
RewardsCalculator: "0x88F83ab63ccf9129Cbb681145F879790d29cC4e6",
|
|
48
|
+
Resolver: "0xa78142B2A829AbA5D737af86a14d2BeEE82dDcF9",
|
|
49
|
+
Factory: "0x9F5973EC7E5f0781E0fCE71Dd949c997c38508Fc"
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
// data/meta.json
|
|
54
|
+
var meta_default = {
|
|
55
|
+
tag: "v0.1",
|
|
56
|
+
source: "https://raw.githubusercontent.com/oikos-cash/core/v0.1/deploy_helper/out/deployment.json",
|
|
57
|
+
fetchedAt: "2026-05-16T19:38:51.457Z",
|
|
58
|
+
sha256: "5e593341d02a2e9f935d0b234401090c6e858a654fed307ad3ccef83d6fedbb7"
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
// src/networks.ts
|
|
62
|
+
var NETWORKS = [
|
|
63
|
+
{
|
|
64
|
+
chainId: 56,
|
|
65
|
+
name: "bsc",
|
|
66
|
+
aliases: ["bsc", "bnb", "binance", "bnbchain", "bsc-mainnet", "bnb-mainnet"]
|
|
67
|
+
}
|
|
68
|
+
];
|
|
69
|
+
|
|
70
|
+
// src/index.ts
|
|
71
|
+
var deployment = deployment_default;
|
|
72
|
+
var meta = meta_default;
|
|
73
|
+
var SOURCE_TAG = meta.tag;
|
|
74
|
+
var SOURCE_URL = meta.source;
|
|
75
|
+
var FETCHED_AT = meta.fetchedAt;
|
|
76
|
+
var SOURCE_SHA256 = meta.sha256;
|
|
77
|
+
function getSourceMeta() {
|
|
78
|
+
return { ...meta };
|
|
79
|
+
}
|
|
80
|
+
function resolveChainId(network) {
|
|
81
|
+
if (typeof network === "number") {
|
|
82
|
+
if (!Number.isFinite(network) || !Number.isInteger(network)) {
|
|
83
|
+
throw new Error(`Invalid chain id: ${network}`);
|
|
84
|
+
}
|
|
85
|
+
return network;
|
|
86
|
+
}
|
|
87
|
+
const s = String(network).toLowerCase().trim();
|
|
88
|
+
if (s === "") throw new Error("Network identifier is empty");
|
|
89
|
+
if (/^\d+$/.test(s)) return Number.parseInt(s, 10);
|
|
90
|
+
const match = NETWORKS.find(
|
|
91
|
+
(n) => n.name === s || n.aliases.includes(s)
|
|
92
|
+
);
|
|
93
|
+
if (!match) {
|
|
94
|
+
const known = NETWORKS.map((n) => `${n.chainId} (${n.name})`).join(", ");
|
|
95
|
+
throw new Error(`Unknown network: "${network}". Known: ${known}`);
|
|
96
|
+
}
|
|
97
|
+
return match.chainId;
|
|
98
|
+
}
|
|
99
|
+
function getAddresses(network) {
|
|
100
|
+
const chainId = resolveChainId(network);
|
|
101
|
+
const addrs = deployment[String(chainId)];
|
|
102
|
+
if (!addrs) {
|
|
103
|
+
throw new Error(`No deployment found for chain id ${chainId}`);
|
|
104
|
+
}
|
|
105
|
+
return { ...addrs };
|
|
106
|
+
}
|
|
107
|
+
function getAddress(network, contract) {
|
|
108
|
+
const addrs = getAddresses(network);
|
|
109
|
+
const addr = addrs[contract];
|
|
110
|
+
if (!addr) {
|
|
111
|
+
throw new Error(
|
|
112
|
+
`Contract "${contract}" not deployed on network ${network}`
|
|
113
|
+
);
|
|
114
|
+
}
|
|
115
|
+
return addr;
|
|
116
|
+
}
|
|
117
|
+
function getSupportedNetworks() {
|
|
118
|
+
return NETWORKS.filter(
|
|
119
|
+
(n) => deployment[String(n.chainId)] !== void 0
|
|
120
|
+
).map((n) => ({ ...n, aliases: [...n.aliases] }));
|
|
121
|
+
}
|
|
122
|
+
function isSupported(network) {
|
|
123
|
+
try {
|
|
124
|
+
const chainId = resolveChainId(network);
|
|
125
|
+
return deployment[String(chainId)] !== void 0;
|
|
126
|
+
} catch {
|
|
127
|
+
return false;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
function getNetworkInfo(network) {
|
|
131
|
+
try {
|
|
132
|
+
const chainId = resolveChainId(network);
|
|
133
|
+
const info = NETWORKS.find((n) => n.chainId === chainId);
|
|
134
|
+
return info ? { ...info, aliases: [...info.aliases] } : void 0;
|
|
135
|
+
} catch {
|
|
136
|
+
return void 0;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
140
|
+
0 && (module.exports = {
|
|
141
|
+
FETCHED_AT,
|
|
142
|
+
NETWORKS,
|
|
143
|
+
SOURCE_SHA256,
|
|
144
|
+
SOURCE_TAG,
|
|
145
|
+
SOURCE_URL,
|
|
146
|
+
deployment,
|
|
147
|
+
getAddress,
|
|
148
|
+
getAddresses,
|
|
149
|
+
getNetworkInfo,
|
|
150
|
+
getSourceMeta,
|
|
151
|
+
getSupportedNetworks,
|
|
152
|
+
isSupported
|
|
153
|
+
});
|
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
type NetworkInfo = {
|
|
2
|
+
chainId: number;
|
|
3
|
+
name: string;
|
|
4
|
+
aliases: readonly string[];
|
|
5
|
+
};
|
|
6
|
+
declare const NETWORKS: readonly NetworkInfo[];
|
|
7
|
+
|
|
8
|
+
type KnownContractName = "Vault" | "Pool" | "Proxy" | "ExchangeHelper" | "ModelHelper" | "AdaptiveSupply" | "RewardsCalculator" | "Resolver" | "Factory";
|
|
9
|
+
type ContractName = KnownContractName | (string & {});
|
|
10
|
+
type ContractAddresses = Record<string, string>;
|
|
11
|
+
type Deployment = Record<string, ContractAddresses>;
|
|
12
|
+
declare const deployment: Deployment;
|
|
13
|
+
type SourceMeta = {
|
|
14
|
+
tag: string;
|
|
15
|
+
source: string;
|
|
16
|
+
fetchedAt: string;
|
|
17
|
+
sha256: string;
|
|
18
|
+
};
|
|
19
|
+
declare const SOURCE_TAG: string;
|
|
20
|
+
declare const SOURCE_URL: string;
|
|
21
|
+
declare const FETCHED_AT: string;
|
|
22
|
+
declare const SOURCE_SHA256: string;
|
|
23
|
+
declare function getSourceMeta(): SourceMeta;
|
|
24
|
+
|
|
25
|
+
declare function getAddresses(network: number | string): ContractAddresses;
|
|
26
|
+
declare function getAddress(network: number | string, contract: ContractName): string;
|
|
27
|
+
declare function getSupportedNetworks(): NetworkInfo[];
|
|
28
|
+
declare function isSupported(network: number | string): boolean;
|
|
29
|
+
declare function getNetworkInfo(network: number | string): NetworkInfo | undefined;
|
|
30
|
+
|
|
31
|
+
export { type ContractAddresses, type ContractName, type Deployment, FETCHED_AT, type KnownContractName, NETWORKS, type NetworkInfo, SOURCE_SHA256, SOURCE_TAG, SOURCE_URL, type SourceMeta, deployment, getAddress, getAddresses, getNetworkInfo, getSourceMeta, getSupportedNetworks, isSupported };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
type NetworkInfo = {
|
|
2
|
+
chainId: number;
|
|
3
|
+
name: string;
|
|
4
|
+
aliases: readonly string[];
|
|
5
|
+
};
|
|
6
|
+
declare const NETWORKS: readonly NetworkInfo[];
|
|
7
|
+
|
|
8
|
+
type KnownContractName = "Vault" | "Pool" | "Proxy" | "ExchangeHelper" | "ModelHelper" | "AdaptiveSupply" | "RewardsCalculator" | "Resolver" | "Factory";
|
|
9
|
+
type ContractName = KnownContractName | (string & {});
|
|
10
|
+
type ContractAddresses = Record<string, string>;
|
|
11
|
+
type Deployment = Record<string, ContractAddresses>;
|
|
12
|
+
declare const deployment: Deployment;
|
|
13
|
+
type SourceMeta = {
|
|
14
|
+
tag: string;
|
|
15
|
+
source: string;
|
|
16
|
+
fetchedAt: string;
|
|
17
|
+
sha256: string;
|
|
18
|
+
};
|
|
19
|
+
declare const SOURCE_TAG: string;
|
|
20
|
+
declare const SOURCE_URL: string;
|
|
21
|
+
declare const FETCHED_AT: string;
|
|
22
|
+
declare const SOURCE_SHA256: string;
|
|
23
|
+
declare function getSourceMeta(): SourceMeta;
|
|
24
|
+
|
|
25
|
+
declare function getAddresses(network: number | string): ContractAddresses;
|
|
26
|
+
declare function getAddress(network: number | string, contract: ContractName): string;
|
|
27
|
+
declare function getSupportedNetworks(): NetworkInfo[];
|
|
28
|
+
declare function isSupported(network: number | string): boolean;
|
|
29
|
+
declare function getNetworkInfo(network: number | string): NetworkInfo | undefined;
|
|
30
|
+
|
|
31
|
+
export { type ContractAddresses, type ContractName, type Deployment, FETCHED_AT, type KnownContractName, NETWORKS, type NetworkInfo, SOURCE_SHA256, SOURCE_TAG, SOURCE_URL, type SourceMeta, deployment, getAddress, getAddresses, getNetworkInfo, getSourceMeta, getSupportedNetworks, isSupported };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
// data/deployment.json
|
|
2
|
+
var deployment_default = {
|
|
3
|
+
"56": {
|
|
4
|
+
Vault: "0x6D77a715d2047a69DFdf922876712c4ef17d1788",
|
|
5
|
+
Pool: "0x104bab30b2983df47dd504114353B0A73bF663CE",
|
|
6
|
+
Proxy: "0x614da16Af43A8Ad0b9F419Ab78d14D163DEa6488",
|
|
7
|
+
ExchangeHelper: "0xe9490B6AA9e3847636CD491f9962Ab2658E589F6",
|
|
8
|
+
ModelHelper: "0x0b94E3c636C967e1e169faeb268C2ca741E9987A",
|
|
9
|
+
AdaptiveSupply: "0xd0581Ba58A5970F83ac1F2f23be09202db96303d",
|
|
10
|
+
RewardsCalculator: "0x88F83ab63ccf9129Cbb681145F879790d29cC4e6",
|
|
11
|
+
Resolver: "0xa78142B2A829AbA5D737af86a14d2BeEE82dDcF9",
|
|
12
|
+
Factory: "0x9F5973EC7E5f0781E0fCE71Dd949c997c38508Fc"
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
// data/meta.json
|
|
17
|
+
var meta_default = {
|
|
18
|
+
tag: "v0.1",
|
|
19
|
+
source: "https://raw.githubusercontent.com/oikos-cash/core/v0.1/deploy_helper/out/deployment.json",
|
|
20
|
+
fetchedAt: "2026-05-16T19:38:51.457Z",
|
|
21
|
+
sha256: "5e593341d02a2e9f935d0b234401090c6e858a654fed307ad3ccef83d6fedbb7"
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
// src/networks.ts
|
|
25
|
+
var NETWORKS = [
|
|
26
|
+
{
|
|
27
|
+
chainId: 56,
|
|
28
|
+
name: "bsc",
|
|
29
|
+
aliases: ["bsc", "bnb", "binance", "bnbchain", "bsc-mainnet", "bnb-mainnet"]
|
|
30
|
+
}
|
|
31
|
+
];
|
|
32
|
+
|
|
33
|
+
// src/index.ts
|
|
34
|
+
var deployment = deployment_default;
|
|
35
|
+
var meta = meta_default;
|
|
36
|
+
var SOURCE_TAG = meta.tag;
|
|
37
|
+
var SOURCE_URL = meta.source;
|
|
38
|
+
var FETCHED_AT = meta.fetchedAt;
|
|
39
|
+
var SOURCE_SHA256 = meta.sha256;
|
|
40
|
+
function getSourceMeta() {
|
|
41
|
+
return { ...meta };
|
|
42
|
+
}
|
|
43
|
+
function resolveChainId(network) {
|
|
44
|
+
if (typeof network === "number") {
|
|
45
|
+
if (!Number.isFinite(network) || !Number.isInteger(network)) {
|
|
46
|
+
throw new Error(`Invalid chain id: ${network}`);
|
|
47
|
+
}
|
|
48
|
+
return network;
|
|
49
|
+
}
|
|
50
|
+
const s = String(network).toLowerCase().trim();
|
|
51
|
+
if (s === "") throw new Error("Network identifier is empty");
|
|
52
|
+
if (/^\d+$/.test(s)) return Number.parseInt(s, 10);
|
|
53
|
+
const match = NETWORKS.find(
|
|
54
|
+
(n) => n.name === s || n.aliases.includes(s)
|
|
55
|
+
);
|
|
56
|
+
if (!match) {
|
|
57
|
+
const known = NETWORKS.map((n) => `${n.chainId} (${n.name})`).join(", ");
|
|
58
|
+
throw new Error(`Unknown network: "${network}". Known: ${known}`);
|
|
59
|
+
}
|
|
60
|
+
return match.chainId;
|
|
61
|
+
}
|
|
62
|
+
function getAddresses(network) {
|
|
63
|
+
const chainId = resolveChainId(network);
|
|
64
|
+
const addrs = deployment[String(chainId)];
|
|
65
|
+
if (!addrs) {
|
|
66
|
+
throw new Error(`No deployment found for chain id ${chainId}`);
|
|
67
|
+
}
|
|
68
|
+
return { ...addrs };
|
|
69
|
+
}
|
|
70
|
+
function getAddress(network, contract) {
|
|
71
|
+
const addrs = getAddresses(network);
|
|
72
|
+
const addr = addrs[contract];
|
|
73
|
+
if (!addr) {
|
|
74
|
+
throw new Error(
|
|
75
|
+
`Contract "${contract}" not deployed on network ${network}`
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
return addr;
|
|
79
|
+
}
|
|
80
|
+
function getSupportedNetworks() {
|
|
81
|
+
return NETWORKS.filter(
|
|
82
|
+
(n) => deployment[String(n.chainId)] !== void 0
|
|
83
|
+
).map((n) => ({ ...n, aliases: [...n.aliases] }));
|
|
84
|
+
}
|
|
85
|
+
function isSupported(network) {
|
|
86
|
+
try {
|
|
87
|
+
const chainId = resolveChainId(network);
|
|
88
|
+
return deployment[String(chainId)] !== void 0;
|
|
89
|
+
} catch {
|
|
90
|
+
return false;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
function getNetworkInfo(network) {
|
|
94
|
+
try {
|
|
95
|
+
const chainId = resolveChainId(network);
|
|
96
|
+
const info = NETWORKS.find((n) => n.chainId === chainId);
|
|
97
|
+
return info ? { ...info, aliases: [...info.aliases] } : void 0;
|
|
98
|
+
} catch {
|
|
99
|
+
return void 0;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
export {
|
|
103
|
+
FETCHED_AT,
|
|
104
|
+
NETWORKS,
|
|
105
|
+
SOURCE_SHA256,
|
|
106
|
+
SOURCE_TAG,
|
|
107
|
+
SOURCE_URL,
|
|
108
|
+
deployment,
|
|
109
|
+
getAddress,
|
|
110
|
+
getAddresses,
|
|
111
|
+
getNetworkInfo,
|
|
112
|
+
getSourceMeta,
|
|
113
|
+
getSupportedNetworks,
|
|
114
|
+
isSupported
|
|
115
|
+
};
|
package/package.json
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@oikos/core-addresses",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Oikos Protocol contract addresses, addressable by network ID or name. Bundled from a pinned oikos-cash/core release tag.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/index.cjs",
|
|
7
|
+
"module": "./dist/index.js",
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"import": {
|
|
12
|
+
"types": "./dist/index.d.ts",
|
|
13
|
+
"default": "./dist/index.js"
|
|
14
|
+
},
|
|
15
|
+
"require": {
|
|
16
|
+
"types": "./dist/index.d.cts",
|
|
17
|
+
"default": "./dist/index.cjs"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"./package.json": "./package.json"
|
|
21
|
+
},
|
|
22
|
+
"bin": {
|
|
23
|
+
"oikos-addresses": "./dist/cli.cjs"
|
|
24
|
+
},
|
|
25
|
+
"files": [
|
|
26
|
+
"dist"
|
|
27
|
+
],
|
|
28
|
+
"scripts": {
|
|
29
|
+
"fetch-deployment": "node scripts/fetch-deployment.mjs",
|
|
30
|
+
"prebuild": "npm run fetch-deployment",
|
|
31
|
+
"build": "tsup",
|
|
32
|
+
"pretypecheck": "npm run fetch-deployment",
|
|
33
|
+
"typecheck": "tsc --noEmit",
|
|
34
|
+
"pretest": "npm run build",
|
|
35
|
+
"test": "node --test test/*.test.mjs",
|
|
36
|
+
"prepare": "npm run build",
|
|
37
|
+
"prepublishOnly": "npm run build"
|
|
38
|
+
},
|
|
39
|
+
"oikosCoreTag": "v0.1",
|
|
40
|
+
"keywords": [
|
|
41
|
+
"oikos",
|
|
42
|
+
"oikos-protocol",
|
|
43
|
+
"addresses",
|
|
44
|
+
"contracts",
|
|
45
|
+
"bnb",
|
|
46
|
+
"bsc",
|
|
47
|
+
"binance-smart-chain",
|
|
48
|
+
"defi",
|
|
49
|
+
"ethereum"
|
|
50
|
+
],
|
|
51
|
+
"license": "MIT",
|
|
52
|
+
"repository": {
|
|
53
|
+
"type": "git",
|
|
54
|
+
"url": "git+https://github.com/oikos-cash/core-addresses.git"
|
|
55
|
+
},
|
|
56
|
+
"homepage": "https://github.com/oikos-cash/core-addresses#readme",
|
|
57
|
+
"bugs": {
|
|
58
|
+
"url": "https://github.com/oikos-cash/core-addresses/issues"
|
|
59
|
+
},
|
|
60
|
+
"engines": {
|
|
61
|
+
"node": ">=18"
|
|
62
|
+
},
|
|
63
|
+
"devDependencies": {
|
|
64
|
+
"@types/node": "^20.19.41",
|
|
65
|
+
"tsup": "^8.3.0",
|
|
66
|
+
"typescript": "^5.6.0"
|
|
67
|
+
}
|
|
68
|
+
}
|