@meddleware/docs 0.0.1
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/CHANGELOG.md +14 -0
- package/LICENSE +14 -0
- package/README.md +54 -0
- package/docs/.vitepress/config.ts +101 -0
- package/docs/.vitepress/theme/custom.css +51 -0
- package/docs/.vitepress/theme/index.ts +8 -0
- package/docs/access-gate/api/functions/buildAccessProof.md +38 -0
- package/docs/access-gate/api/functions/buildAirdropTx.md +21 -0
- package/docs/access-gate/api/functions/buildConsumeTx.md +27 -0
- package/docs/access-gate/api/functions/buildCreateGateTx.md +52 -0
- package/docs/access-gate/api/functions/buildMakeGateImmutableTx.md +19 -0
- package/docs/access-gate/api/functions/buildPurchaseTx.md +23 -0
- package/docs/access-gate/api/functions/buildSetAutoBurnAtZeroTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetDefaultUsesTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetNftDescriptionTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetNftImageUrlTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetNftNameTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetPausedTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetPaymentRecipientTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetPriceTx.md +21 -0
- package/docs/access-gate/api/functions/buildSetSoulboundTx.md +21 -0
- package/docs/access-gate/api/functions/decodeAccessProof.md +17 -0
- package/docs/access-gate/api/functions/encodeAccessProof.md +17 -0
- package/docs/access-gate/api/functions/fetchAccessNftById.md +27 -0
- package/docs/access-gate/api/functions/fetchAccessNfts.md +34 -0
- package/docs/access-gate/api/functions/fetchAdminCaps.md +30 -0
- package/docs/access-gate/api/functions/fetchChallenge.md +32 -0
- package/docs/access-gate/api/functions/fetchGate.md +26 -0
- package/docs/access-gate/api/functions/fetchOwnedGates.md +31 -0
- package/docs/access-gate/api/functions/ownsAccessNft.md +35 -0
- package/docs/access-gate/api/functions/parseAdminCap.md +26 -0
- package/docs/access-gate/api/functions/parseGate.md +19 -0
- package/docs/access-gate/api/functions/parseOwnedAccessNft.md +19 -0
- package/docs/access-gate/api/functions/personalMessageForNonce.md +18 -0
- package/docs/access-gate/api/index.md +47 -0
- package/docs/access-gate/api/interfaces/AccessGateConfig.md +57 -0
- package/docs/access-gate/api/interfaces/AccessProof.md +46 -0
- package/docs/access-gate/api/interfaces/Challenge.md +25 -0
- package/docs/access-gate/api/interfaces/GateAdminContext.md +37 -0
- package/docs/access-gate/api/interfaces/OwnedAccessNft.md +31 -0
- package/docs/access-gate/api/interfaces/OwnedGate.md +125 -0
- package/docs/access-gate/api/interfaces/OwnedObjectsClient.md +49 -0
- package/docs/access-gate/api/interfaces/SuiObjectClient.md +37 -0
- package/docs/access-gate/api/type-aliases/PersonalMessageSigner.md +17 -0
- package/docs/access-gate/api/typedoc-sidebar.json +1 -0
- package/docs/access-gate/index.md +61 -0
- package/docs/access-gate/reference.md +111 -0
- package/docs/access-gate/using.md +68 -0
- package/docs/architecture.md +61 -0
- package/docs/dao/index.md +71 -0
- package/docs/dao/reference.md +94 -0
- package/docs/getting-started.md +59 -0
- package/docs/index.md +58 -0
- package/docs/sealed-storage/api/classes/PolicyRegistry.md +103 -0
- package/docs/sealed-storage/api/classes/SealController.md +113 -0
- package/docs/sealed-storage/api/functions/buildPublishSealedContentTx.md +27 -0
- package/docs/sealed-storage/api/functions/bytesToHex.md +17 -0
- package/docs/sealed-storage/api/functions/concatBytes.md +17 -0
- package/docs/sealed-storage/api/functions/createDefaultRegistry.md +22 -0
- package/docs/sealed-storage/api/functions/createNftGateProvider.md +21 -0
- package/docs/sealed-storage/api/functions/hexToBytes.md +17 -0
- package/docs/sealed-storage/api/functions/objectIdBytes.md +17 -0
- package/docs/sealed-storage/api/functions/randomBytes.md +17 -0
- package/docs/sealed-storage/api/functions/sealedContentEventType.md +17 -0
- package/docs/sealed-storage/api/functions/u64beBytes.md +17 -0
- package/docs/sealed-storage/api/index.md +45 -0
- package/docs/sealed-storage/api/interfaces/EncryptResult.md +23 -0
- package/docs/sealed-storage/api/interfaces/FieldSpec.md +51 -0
- package/docs/sealed-storage/api/interfaces/FieldSuggestion.md +21 -0
- package/docs/sealed-storage/api/interfaces/KeyServerConfig.md +35 -0
- package/docs/sealed-storage/api/interfaces/NftGateParams.md +33 -0
- package/docs/sealed-storage/api/interfaces/PolicyDescriptor.md +49 -0
- package/docs/sealed-storage/api/interfaces/SealControllerConfig.md +63 -0
- package/docs/sealed-storage/api/interfaces/SealPolicyProvider.md +115 -0
- package/docs/sealed-storage/api/interfaces/SealSuggestClient.md +74 -0
- package/docs/sealed-storage/api/interfaces/SealedContentInput.md +45 -0
- package/docs/sealed-storage/api/interfaces/SealedContentPointer.md +53 -0
- package/docs/sealed-storage/api/interfaces/SealedManifest.md +65 -0
- package/docs/sealed-storage/api/interfaces/SuggestContext.md +25 -0
- package/docs/sealed-storage/api/interfaces/TimeLockParams.md +13 -0
- package/docs/sealed-storage/api/type-aliases/SignPersonalMessage.md +17 -0
- package/docs/sealed-storage/api/typedoc-sidebar.json +1 -0
- package/docs/sealed-storage/api/variables/nftGateProvider.md +9 -0
- package/docs/sealed-storage/api/variables/timeLockProvider.md +9 -0
- package/docs/sealed-storage/index.md +68 -0
- package/docs/sealed-storage/policies.md +52 -0
- package/docs/sealed-storage/reference.md +79 -0
- package/docs/sealed-storage/using.md +55 -0
- package/docs/walrus-storage/api/classes/RetryableWalrusClientError.md +101 -0
- package/docs/walrus-storage/api/classes/WalrusFile.md +111 -0
- package/docs/walrus-storage/api/functions/buildAccessProofToken.md +21 -0
- package/docs/walrus-storage/api/functions/certifyBlobTransaction.md +30 -0
- package/docs/walrus-storage/api/functions/createBlobUploadFlow.md +30 -0
- package/docs/walrus-storage/api/functions/createRelayAccessToken.md +45 -0
- package/docs/walrus-storage/api/functions/createUploadFlow.md +30 -0
- package/docs/walrus-storage/api/functions/createWalrusClient.md +23 -0
- package/docs/walrus-storage/api/functions/estimateStorageCost.md +35 -0
- package/docs/walrus-storage/api/functions/extendBlobLifetime.md +40 -0
- package/docs/walrus-storage/api/functions/extendBlobLifetimeTransaction.md +34 -0
- package/docs/walrus-storage/api/functions/fetchOwnedWalrusBlobs.md +34 -0
- package/docs/walrus-storage/api/functions/fetchRelayChallenge.md +32 -0
- package/docs/walrus-storage/api/functions/getWalrusPackageConfig.md +25 -0
- package/docs/walrus-storage/api/functions/personalMessageForNonce.md +18 -0
- package/docs/walrus-storage/api/functions/readBlobAttributes.md +27 -0
- package/docs/walrus-storage/api/functions/setBlobAttributes.md +40 -0
- package/docs/walrus-storage/api/functions/setBlobAttributesTransaction.md +34 -0
- package/docs/walrus-storage/api/functions/uploadBytes.md +38 -0
- package/docs/walrus-storage/api/functions/uploadImageBytes.md +34 -0
- package/docs/walrus-storage/api/functions/uploadLocalFile.md +37 -0
- package/docs/walrus-storage/api/functions/walrusBlobUrl.md +26 -0
- package/docs/walrus-storage/api/index.md +56 -0
- package/docs/walrus-storage/api/interfaces/CertifyOptions.md +46 -0
- package/docs/walrus-storage/api/interfaces/StorageCost.md +35 -0
- package/docs/walrus-storage/api/type-aliases/AccessProofInput.md +7 -0
- package/docs/walrus-storage/api/type-aliases/CreateWalrusClientOptions.md +113 -0
- package/docs/walrus-storage/api/type-aliases/ExtendOptions.md +8 -0
- package/docs/walrus-storage/api/type-aliases/OwnedBlob.md +57 -0
- package/docs/walrus-storage/api/type-aliases/PersonalMessageSigner.md +17 -0
- package/docs/walrus-storage/api/type-aliases/RelayChallenge.md +7 -0
- package/docs/walrus-storage/api/type-aliases/UploadOptions.md +37 -0
- package/docs/walrus-storage/api/type-aliases/UploadResult.md +27 -0
- package/docs/walrus-storage/api/type-aliases/WalrusClient.md +7 -0
- package/docs/walrus-storage/api/type-aliases/WalrusNetwork.md +7 -0
- package/docs/walrus-storage/api/typedoc-sidebar.json +1 -0
- package/docs/walrus-storage/api/variables/DEFAULT_RPC_URLS.md +7 -0
- package/docs/walrus-storage/api/variables/LONG_TERM_EPOCHS.md +12 -0
- package/docs/walrus-storage/api/variables/MAINNET_WALRUS_PACKAGE_CONFIG.md +15 -0
- package/docs/walrus-storage/api/variables/PUBLIC_UPLOAD_RELAY_HOSTS.md +10 -0
- package/docs/walrus-storage/api/variables/TESTNET_WALRUS_PACKAGE_CONFIG.md +19 -0
- package/docs/walrus-storage/api/variables/WALRUS_AGGREGATOR_HOSTS.md +7 -0
- package/docs/walrus-storage/index.md +54 -0
- package/docs/walrus-storage/reference.md +69 -0
- package/docs/walrus-storage/using.md +53 -0
- package/package.json +50 -0
- package/scripts/gen-api.mjs +107 -0
- package/tsconfig.json +13 -0
- package/tsconfig.typedoc.json +20 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to `@meddleware/docs` are documented here.
|
|
4
|
+
|
|
5
|
+
## [0.0.1] — 2026-09-17
|
|
6
|
+
|
|
7
|
+
Initial release. VitePress documentation site for `docs.meddleware.co.uk` covering the four
|
|
8
|
+
Meddleware Sui tools: DAO, Walrus Storage, Sealed Storage, and Access Gate.
|
|
9
|
+
|
|
10
|
+
- Hand-authored narrative (what/how/when) for all four tools
|
|
11
|
+
- Auto-generated SDK API reference via TypeDoc (walrus-client, seal-client, nft-gate-client)
|
|
12
|
+
- On-brand via `@meddleware/design-tokens` (Oxblood/Indigo/Gold)
|
|
13
|
+
- Local search across all sections
|
|
14
|
+
- Dark-first appearance
|
package/LICENSE
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
BSD Zero Clause License
|
|
2
|
+
|
|
3
|
+
Copyright (c) Meddleware
|
|
4
|
+
|
|
5
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
+
purpose with or without fee is hereby granted.
|
|
7
|
+
|
|
8
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
9
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
|
10
|
+
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
11
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
|
|
12
|
+
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
|
|
13
|
+
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
|
|
14
|
+
THIS SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# @meddleware/docs
|
|
2
|
+
|
|
3
|
+
User-facing documentation for the Meddleware Sui tools, served at
|
|
4
|
+
[`docs.meddleware.co.uk`](https://docs.meddleware.co.uk). Built with [VitePress](https://vitepress.dev).
|
|
5
|
+
|
|
6
|
+
One site, one section per service — **DAO**, **Walrus Storage**, **Sealed Storage**, **Access Gate** —
|
|
7
|
+
each answering *what it is*, *how to use it*, and *when to use it*, plus a reference layer (object/
|
|
8
|
+
event shapes and auto-generated SDK API).
|
|
9
|
+
|
|
10
|
+
## Structure
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
docs/
|
|
14
|
+
index.md Landing / overview
|
|
15
|
+
getting-started.md Wallet basics, testnet vs mainnet, first steps
|
|
16
|
+
architecture.md How the four tools fit together
|
|
17
|
+
dao/ DAO console
|
|
18
|
+
walrus-storage/ Decentralised blob storage
|
|
19
|
+
sealed-storage/ Encrypted, access-gated storage
|
|
20
|
+
access-gate/ NFT access gates
|
|
21
|
+
.vitepress/
|
|
22
|
+
config.ts Nav, sidebar, search, brand theme
|
|
23
|
+
theme/ Design-token brand overrides
|
|
24
|
+
scripts/gen-api.mjs TypeDoc autodoc for the SDK reference sections
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Develop
|
|
28
|
+
|
|
29
|
+
```sh
|
|
30
|
+
npm install
|
|
31
|
+
npm run dev # gen:api (TypeDoc) + vitepress dev → http://localhost:5173
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Build
|
|
35
|
+
|
|
36
|
+
```sh
|
|
37
|
+
npm run build # gen:api + vitepress build → dist/
|
|
38
|
+
docker build -t docs .
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
The build emits a static site to `dist/` (pinned via `outDir` in `.vitepress/config.ts`), which the
|
|
42
|
+
runtime image serves with the shared `static-server`.
|
|
43
|
+
|
|
44
|
+
## Content boundary
|
|
45
|
+
|
|
46
|
+
This site is **user-facing**. Developer integration guides, self-host instructions, and white-label
|
|
47
|
+
operator guides are intentionally **out of scope** — they live (planned) in each package's
|
|
48
|
+
README/CLAUDE.md and will surface on the future `dev.meddleware.co.uk`. The auto-generated SDK API
|
|
49
|
+
reference *is* included here (useful to users and bots) but without the "wire it into your app"
|
|
50
|
+
tutorials.
|
|
51
|
+
|
|
52
|
+
## License
|
|
53
|
+
|
|
54
|
+
BSD Zero Clause License (`0BSD`). See [LICENSE](LICENSE).
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import { defineConfig } from 'vitepress'
|
|
2
|
+
import { fileURLToPath } from 'node:url'
|
|
3
|
+
|
|
4
|
+
// User-facing documentation for the Meddleware Sui tools. One site, one section per service.
|
|
5
|
+
// Output is pinned to the repo-root dist/ so the Dockerfile's `COPY --from=build /app/dist`
|
|
6
|
+
// (the shared static-server image pattern) works unchanged.
|
|
7
|
+
const outDir = fileURLToPath(new URL('../../dist', import.meta.url))
|
|
8
|
+
|
|
9
|
+
export default defineConfig({
|
|
10
|
+
title: 'Meddleware Docs',
|
|
11
|
+
description:
|
|
12
|
+
'How to use the Meddleware Sui tools — the DAO console, Walrus Storage, Sealed Storage, and Access Gate.',
|
|
13
|
+
lang: 'en-GB',
|
|
14
|
+
outDir,
|
|
15
|
+
cleanUrls: true,
|
|
16
|
+
lastUpdated: true,
|
|
17
|
+
// The per-service `api/` subtrees are generated at build time by scripts/gen-api.mjs (TypeDoc);
|
|
18
|
+
// their exact filenames depend on the TypeDoc version, so don't fail the build on links into them.
|
|
19
|
+
ignoreDeadLinks: [/\/api\//],
|
|
20
|
+
// Match the estate's dark-first aesthetic; users can still toggle.
|
|
21
|
+
appearance: 'dark',
|
|
22
|
+
head: [['meta', { name: 'theme-color', content: '#5e1622' }]],
|
|
23
|
+
|
|
24
|
+
themeConfig: {
|
|
25
|
+
search: { provider: 'local' },
|
|
26
|
+
|
|
27
|
+
nav: [
|
|
28
|
+
{ text: 'Start here', link: '/getting-started' },
|
|
29
|
+
{ text: 'DAO', link: '/dao/' },
|
|
30
|
+
{ text: 'Walrus Storage', link: '/walrus-storage/' },
|
|
31
|
+
{ text: 'Sealed Storage', link: '/sealed-storage/' },
|
|
32
|
+
{ text: 'Access Gate', link: '/access-gate/' },
|
|
33
|
+
{
|
|
34
|
+
text: 'Tools',
|
|
35
|
+
items: [
|
|
36
|
+
{ text: 'Tools hub', link: 'https://sui.meddleware.co.uk' },
|
|
37
|
+
{ text: 'DAO console', link: 'https://sui-dao.meddleware.co.uk' },
|
|
38
|
+
{ text: 'Walrus Storage', link: 'https://sui-walrus.meddleware.co.uk' },
|
|
39
|
+
{ text: 'Sealed Storage', link: 'https://sui-seal.meddleware.co.uk' },
|
|
40
|
+
{ text: 'Access Gate', link: 'https://sui-access-gate.meddleware.co.uk' },
|
|
41
|
+
],
|
|
42
|
+
},
|
|
43
|
+
],
|
|
44
|
+
|
|
45
|
+
sidebar: {
|
|
46
|
+
'/': [
|
|
47
|
+
{
|
|
48
|
+
text: 'Introduction',
|
|
49
|
+
items: [
|
|
50
|
+
{ text: 'Overview', link: '/' },
|
|
51
|
+
{ text: 'Getting started', link: '/getting-started' },
|
|
52
|
+
{ text: 'How the tools fit together', link: '/architecture' },
|
|
53
|
+
],
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
text: 'DAO',
|
|
57
|
+
collapsed: false,
|
|
58
|
+
items: [
|
|
59
|
+
{ text: 'Overview', link: '/dao/' },
|
|
60
|
+
{ text: 'Reference', link: '/dao/reference' },
|
|
61
|
+
],
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
text: 'Walrus Storage',
|
|
65
|
+
collapsed: false,
|
|
66
|
+
items: [
|
|
67
|
+
{ text: 'Overview', link: '/walrus-storage/' },
|
|
68
|
+
{ text: 'Using it', link: '/walrus-storage/using' },
|
|
69
|
+
{ text: 'Reference', link: '/walrus-storage/reference' },
|
|
70
|
+
],
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
text: 'Sealed Storage',
|
|
74
|
+
collapsed: false,
|
|
75
|
+
items: [
|
|
76
|
+
{ text: 'Overview', link: '/sealed-storage/' },
|
|
77
|
+
{ text: 'Using it', link: '/sealed-storage/using' },
|
|
78
|
+
{ text: 'Policies', link: '/sealed-storage/policies' },
|
|
79
|
+
{ text: 'Reference', link: '/sealed-storage/reference' },
|
|
80
|
+
],
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
text: 'Access Gate',
|
|
84
|
+
collapsed: false,
|
|
85
|
+
items: [
|
|
86
|
+
{ text: 'Overview', link: '/access-gate/' },
|
|
87
|
+
{ text: 'Using it', link: '/access-gate/using' },
|
|
88
|
+
{ text: 'Reference', link: '/access-gate/reference' },
|
|
89
|
+
],
|
|
90
|
+
},
|
|
91
|
+
],
|
|
92
|
+
},
|
|
93
|
+
|
|
94
|
+
socialLinks: [{ icon: 'github', link: 'https://github.com/meddleware-org' }],
|
|
95
|
+
|
|
96
|
+
footer: {
|
|
97
|
+
message: 'Documentation for the Meddleware Sui tools.',
|
|
98
|
+
copyright: 'Meddleware · 0BSD',
|
|
99
|
+
},
|
|
100
|
+
},
|
|
101
|
+
})
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Meddleware brand overrides for the VitePress default theme.
|
|
3
|
+
* Brand ramp = Oxblood (primary) with Indigo/Gold accents, sourced from
|
|
4
|
+
* @meddleware/design-tokens so the docs stay in lockstep with the apps.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:root {
|
|
8
|
+
/* Brand = Oxblood */
|
|
9
|
+
--vp-c-brand-1: var(--mw-oxblood-500);
|
|
10
|
+
--vp-c-brand-2: var(--mw-oxblood-400);
|
|
11
|
+
--vp-c-brand-3: var(--mw-oxblood-400);
|
|
12
|
+
--vp-c-brand-soft: var(--mw-oxblood-100);
|
|
13
|
+
|
|
14
|
+
/* Home hero: Oxblood → Indigo wash, Gold glow */
|
|
15
|
+
--vp-home-hero-name-color: transparent;
|
|
16
|
+
--vp-home-hero-name-background: linear-gradient(
|
|
17
|
+
120deg,
|
|
18
|
+
var(--mw-oxblood-500),
|
|
19
|
+
var(--mw-indigo-500)
|
|
20
|
+
);
|
|
21
|
+
--vp-home-hero-image-background-image: linear-gradient(
|
|
22
|
+
120deg,
|
|
23
|
+
var(--mw-oxblood-400),
|
|
24
|
+
var(--mw-gold-500)
|
|
25
|
+
);
|
|
26
|
+
--vp-home-hero-image-filter: blur(44px);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.dark {
|
|
30
|
+
/* Dark mode: lightened Oxblood for legibility (mirrors --accent in tokens) */
|
|
31
|
+
--vp-c-brand-1: #b0465a;
|
|
32
|
+
--vp-c-brand-2: var(--mw-oxblood-400);
|
|
33
|
+
--vp-c-brand-3: var(--mw-oxblood-500);
|
|
34
|
+
--vp-c-brand-soft: color-mix(in srgb, var(--mw-oxblood-500) 30%, transparent);
|
|
35
|
+
|
|
36
|
+
--vp-home-hero-name-background: linear-gradient(
|
|
37
|
+
120deg,
|
|
38
|
+
#b0465a,
|
|
39
|
+
var(--mw-indigo-300)
|
|
40
|
+
);
|
|
41
|
+
--vp-home-hero-image-background-image: linear-gradient(
|
|
42
|
+
120deg,
|
|
43
|
+
var(--mw-oxblood-500),
|
|
44
|
+
var(--mw-gold-400)
|
|
45
|
+
);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/* Gold for "tip" custom blocks keeps the accent role consistent with the apps. */
|
|
49
|
+
.vp-doc .custom-block.tip {
|
|
50
|
+
border-color: var(--mw-gold-500);
|
|
51
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
// Docs theme = VitePress default theme + Meddleware brand overrides.
|
|
2
|
+
// The design-token CSS is imported so the palette stays in lockstep with the apps; custom.css
|
|
3
|
+
// maps VitePress's --vp-c-brand-* onto the Oxblood/Indigo/Gold ramps.
|
|
4
|
+
import DefaultTheme from 'vitepress/theme'
|
|
5
|
+
import '@meddleware/design-tokens/tokens.css'
|
|
6
|
+
import './custom.css'
|
|
7
|
+
|
|
8
|
+
export default DefaultTheme
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Function: buildAccessProof()
|
|
2
|
+
|
|
3
|
+
> **buildAccessProof**(`opts`): `Promise`\<`string`\>
|
|
4
|
+
|
|
5
|
+
Defined in: proof.ts:44
|
|
6
|
+
|
|
7
|
+
Sign a challenge and assemble the encoded access-proof token to hand to any gateway as its
|
|
8
|
+
auth bearer (e.g. an upload-relay client's auth-token option, an `Authorization` header).
|
|
9
|
+
|
|
10
|
+
## Parameters
|
|
11
|
+
|
|
12
|
+
### opts
|
|
13
|
+
|
|
14
|
+
#### address
|
|
15
|
+
|
|
16
|
+
`string`
|
|
17
|
+
|
|
18
|
+
#### challenge
|
|
19
|
+
|
|
20
|
+
[`Challenge`](../interfaces/Challenge.md)
|
|
21
|
+
|
|
22
|
+
#### consumeDigest?
|
|
23
|
+
|
|
24
|
+
`string`
|
|
25
|
+
|
|
26
|
+
Present for single-use gates: the `consume` tx digest.
|
|
27
|
+
|
|
28
|
+
#### sign
|
|
29
|
+
|
|
30
|
+
[`PersonalMessageSigner`](../type-aliases/PersonalMessageSigner.md)
|
|
31
|
+
|
|
32
|
+
## Returns
|
|
33
|
+
|
|
34
|
+
`Promise`\<`string`\>
|
|
35
|
+
|
|
36
|
+
## Throws
|
|
37
|
+
|
|
38
|
+
if the wallet signer rejects or fails to sign the message.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildAirdropTx()
|
|
2
|
+
|
|
3
|
+
> **buildAirdropTx**(`ctx`, `recipient`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:142
|
|
6
|
+
|
|
7
|
+
AdminCap-gated free grant (airdrop) of the gate's NFT flavour to `recipient`.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### recipient
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Function: buildConsumeTx()
|
|
2
|
+
|
|
3
|
+
> **buildConsumeTx**(`cfg`, `nftId`, `nonce`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:24
|
|
6
|
+
|
|
7
|
+
Build a PTB that consumes one use of a single-use NFT, binding it to `nonce`. Selects
|
|
8
|
+
`consume` or `consume_soulbound` from `cfg.soulbound`. For unlimited passes there is
|
|
9
|
+
nothing to consume — do not call this.
|
|
10
|
+
|
|
11
|
+
## Parameters
|
|
12
|
+
|
|
13
|
+
### cfg
|
|
14
|
+
|
|
15
|
+
[`AccessGateConfig`](../interfaces/AccessGateConfig.md)
|
|
16
|
+
|
|
17
|
+
### nftId
|
|
18
|
+
|
|
19
|
+
`string`
|
|
20
|
+
|
|
21
|
+
### nonce
|
|
22
|
+
|
|
23
|
+
`string`
|
|
24
|
+
|
|
25
|
+
## Returns
|
|
26
|
+
|
|
27
|
+
`Transaction`
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# Function: buildCreateGateTx()
|
|
2
|
+
|
|
3
|
+
> **buildCreateGateTx**(`packageId`, `opts`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:43
|
|
6
|
+
|
|
7
|
+
Build a PTB that creates a new gate. Mostly for tooling/operators; the frontend usually
|
|
8
|
+
only purchases/consumes an existing gate.
|
|
9
|
+
|
|
10
|
+
## Parameters
|
|
11
|
+
|
|
12
|
+
### packageId
|
|
13
|
+
|
|
14
|
+
`string`
|
|
15
|
+
|
|
16
|
+
### opts
|
|
17
|
+
|
|
18
|
+
#### autoBurnAtZero
|
|
19
|
+
|
|
20
|
+
`boolean`
|
|
21
|
+
|
|
22
|
+
#### defaultUses
|
|
23
|
+
|
|
24
|
+
`number` \| `bigint`
|
|
25
|
+
|
|
26
|
+
#### nftDescription
|
|
27
|
+
|
|
28
|
+
`string`
|
|
29
|
+
|
|
30
|
+
#### nftImageUrl
|
|
31
|
+
|
|
32
|
+
`string`
|
|
33
|
+
|
|
34
|
+
#### nftName
|
|
35
|
+
|
|
36
|
+
`string`
|
|
37
|
+
|
|
38
|
+
#### paymentRecipient
|
|
39
|
+
|
|
40
|
+
`string`
|
|
41
|
+
|
|
42
|
+
#### priceMist
|
|
43
|
+
|
|
44
|
+
`number` \| `bigint`
|
|
45
|
+
|
|
46
|
+
#### soulbound
|
|
47
|
+
|
|
48
|
+
`boolean`
|
|
49
|
+
|
|
50
|
+
## Returns
|
|
51
|
+
|
|
52
|
+
`Transaction`
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Function: buildMakeGateImmutableTx()
|
|
2
|
+
|
|
3
|
+
> **buildMakeGateImmutableTx**(`ctx`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:151
|
|
6
|
+
|
|
7
|
+
Make the gate immutable — **irreversible**. Consumes the `AdminCap` (passed by value) and sets
|
|
8
|
+
`Gate.frozen = true`, permanently ending all setters and `airdrop`. `purchase`/`consume` remain
|
|
9
|
+
permissionless. Grant everything first, then freeze.
|
|
10
|
+
|
|
11
|
+
## Parameters
|
|
12
|
+
|
|
13
|
+
### ctx
|
|
14
|
+
|
|
15
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
16
|
+
|
|
17
|
+
## Returns
|
|
18
|
+
|
|
19
|
+
`Transaction`
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Function: buildPurchaseTx()
|
|
2
|
+
|
|
3
|
+
> **buildPurchaseTx**(`cfg`, `priceMist`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:9
|
|
6
|
+
|
|
7
|
+
Build a PTB that purchases access: split `priceMist` from the gas coin and call
|
|
8
|
+
`access_gate::purchase(gate, payment)`. Overpayment is refunded on-chain, so the split
|
|
9
|
+
must be exactly the price. The caller signs + executes with their wallet.
|
|
10
|
+
|
|
11
|
+
## Parameters
|
|
12
|
+
|
|
13
|
+
### cfg
|
|
14
|
+
|
|
15
|
+
[`AccessGateConfig`](../interfaces/AccessGateConfig.md)
|
|
16
|
+
|
|
17
|
+
### priceMist
|
|
18
|
+
|
|
19
|
+
`number` \| `bigint`
|
|
20
|
+
|
|
21
|
+
## Returns
|
|
22
|
+
|
|
23
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetAutoBurnAtZeroTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetAutoBurnAtZeroTx**(`ctx`, `autoBurn`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:122
|
|
6
|
+
|
|
7
|
+
Toggle the auto-burn-at-zero policy for future mints.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### autoBurn
|
|
16
|
+
|
|
17
|
+
`boolean`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetDefaultUsesTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetDefaultUsesTx**(`ctx`, `defaultUses`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:112
|
|
6
|
+
|
|
7
|
+
Change the default uses for future mints (0 ⇒ unlimited pass; N ⇒ single-use with N).
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### defaultUses
|
|
16
|
+
|
|
17
|
+
`number` \| `bigint`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetNftDescriptionTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetNftDescriptionTx**(`ctx`, `description`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:137
|
|
6
|
+
|
|
7
|
+
Update the default NFT description for future mints.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### description
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetNftImageUrlTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetNftImageUrlTx**(`ctx`, `url`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:132
|
|
6
|
+
|
|
7
|
+
Update the default NFT image URL for future mints.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### url
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetNftNameTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetNftNameTx**(`ctx`, `name`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:127
|
|
6
|
+
|
|
7
|
+
Update the default NFT display name for future mints.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### name
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetPausedTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetPausedTx**(`ctx`, `paused`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:107
|
|
6
|
+
|
|
7
|
+
Pause or unpause `purchase` (paused ⇒ `purchase` aborts with `E_PAUSED`).
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### paused
|
|
16
|
+
|
|
17
|
+
`boolean`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetPaymentRecipientTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetPaymentRecipientTx**(`ctx`, `recipient`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:102
|
|
6
|
+
|
|
7
|
+
Redirect future purchase payments to a new recipient address.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### recipient
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetPriceTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetPriceTx**(`ctx`, `priceMist`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:97
|
|
6
|
+
|
|
7
|
+
Set the gate price (in MIST) charged by future `purchase` calls (0 = free).
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### priceMist
|
|
16
|
+
|
|
17
|
+
`number` \| `bigint`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Function: buildSetSoulboundTx()
|
|
2
|
+
|
|
3
|
+
> **buildSetSoulboundTx**(`ctx`, `soulbound`): `Transaction`
|
|
4
|
+
|
|
5
|
+
Defined in: ptb.ts:117
|
|
6
|
+
|
|
7
|
+
Switch the soulbound flag for future mints (does not affect already-minted NFTs).
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### ctx
|
|
12
|
+
|
|
13
|
+
[`GateAdminContext`](../interfaces/GateAdminContext.md)
|
|
14
|
+
|
|
15
|
+
### soulbound
|
|
16
|
+
|
|
17
|
+
`boolean`
|
|
18
|
+
|
|
19
|
+
## Returns
|
|
20
|
+
|
|
21
|
+
`Transaction`
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Function: decodeAccessProof()
|
|
2
|
+
|
|
3
|
+
> **decodeAccessProof**(`token`): [`AccessProof`](../interfaces/AccessProof.md)
|
|
4
|
+
|
|
5
|
+
Defined in: proof.ts:25
|
|
6
|
+
|
|
7
|
+
Decode a proof token produced by [encodeAccessProof](encodeAccessProof.md). Throws on malformed input.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### token
|
|
12
|
+
|
|
13
|
+
`string`
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
[`AccessProof`](../interfaces/AccessProof.md)
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Function: encodeAccessProof()
|
|
2
|
+
|
|
3
|
+
> **encodeAccessProof**(`proof`): `string`
|
|
4
|
+
|
|
5
|
+
Defined in: proof.ts:20
|
|
6
|
+
|
|
7
|
+
Encode a proof as the compact Bearer token carried in the relay auth header.
|
|
8
|
+
|
|
9
|
+
## Parameters
|
|
10
|
+
|
|
11
|
+
### proof
|
|
12
|
+
|
|
13
|
+
[`AccessProof`](../interfaces/AccessProof.md)
|
|
14
|
+
|
|
15
|
+
## Returns
|
|
16
|
+
|
|
17
|
+
`string`
|