PageSourceSearch

https://docs.hazbase.com/start/day0/

html hazbase.com collected 2026-10-05 06:31:12 UTC 23,137 bytes, 35 lines download raw bytes

1<!DOCTYPE html>
2<html lang="ja"><head><meta charset="UTF-8"/><meta name="viewport" content="width=device-width, initial-scale=1.0"/>
3
4
5<meta name="author" content="IndieSquare Inc."/>
6
7
8<link rel="icon" type="image/svg+xml" href="/brand/favicon.svg"/>
9  
9<script type="module" crossorigin src="/assets/index-BAAzACLV.js"></script>
9
10  <link rel="stylesheet" crossorigin href="/assets/index-DZzkPOxE.css">
11<title>はじめてのRWAアプリケーション | hazBase Docs</title><meta name="description" content="サンプルアプリを使って、トークンの発行・割当・移転と保有数の確認を行います。設備・在庫・利用権から用途を選び、名称や発行上限を設定して始められます。"/><meta name="robots" content="index,follow"/><meta property="og:title" content="はじめてのRWAアプリケーション | hazBase Docs"/><meta property="og:description" content="サンプルアプリを使って、トークンの発行・割当・移転と保有数の確認を行います。設備・在庫・利用権から用途を選び、名称や発行上限を設定して始められます。"/><meta property="og:type" content="website"/><meta property="og:site_name" content="hazBase Docs"/><meta property="og:url" content="https://docs.hazbase.com/start/day0/"/><meta property="og:locale" content="ja_JP"/><meta property="og:locale:alternate" content="en_US"/><meta name="twitter:card" content="summary_large_image"/><meta name="twitter:title" content="はじめてのRWAアプリケーション | hazBase Docs"/><meta name="twitter:description" content="サンプルアプリを使って、トークンの発行・割当・移転と保有数の確認を行います。設備・在庫・利用権から用途を選び、名称や発行上限を設定して始められます。"/><meta property="og:image" content="https://docs.hazbase.com/og.png"/><meta property="og:image:width" content="1200"/><meta property="og:image:height" content="630"/><meta property="og:image:type" content="image/png"/><meta property="og:image:alt" content="hazBase Docs — RWA開発を、実装へ。API・SDK・実装ガイド"/><meta name="twitter:image" content="https://docs.hazbase.com/og.png"/><meta name="twitter:image:alt" content="hazBase Docs — RWA開発を、実装へ。API・SDK・実装ガイド"/><link rel="canonical" href="https://docs.hazbase.com/start/day0/"/><link rel="alternate" hreflang="ja" href="https://docs.hazbase.com/start/day0/"/><link rel="alternate" hreflang="en" href="https://docs.hazbase.com/en/start/day0/"/><link rel="alternate" hreflang="x-default" href="https://docs.hazbase.com/start/day0/"/><link rel="alternate" type="text/plain" title="Plain text" href="/content/ja/start/day0.txt"/></head><body><div id="root"><div role="region" aria-label="Notifications (F8)" tabindex="-1" style="pointer-events:none"><ol tabindex="-1" class="fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]"></ol></div><section aria-label="Notifications alt+T" tabindex="-1" aria-live="polite" aria-relevant="additions text" aria-atomic="false"></section><div class="docs-frame"><a href="#docs-main" class="docs-skip">本文へ移動</a><header class="docs-header"><a class="docs-brand" aria-label="hazBase Docs" href="/"><img class="brand-light" src="/brand/hazbase-logo-primary.svg" alt="hazBase" width="365" height="80"/><img class="brand-dark" src="/brand/hazbase-logo-inverse.svg" alt="hazBase" width="365" height="80"/><span>Docs</span></a><button class="docs-search-button"><svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-search"><circle cx="11" cy="11" r="8"></circle><path d="m21 21-4.3-4.3"></path></svg><span>ドキュメントを検索</span><kbd>⌘ K</kbd></button><div class="docs-header-tools"><a href="https://console.hazbase.com/clients" class="docs-console-link" aria-label="コンソールを開く"><span class="docs-console-full-label">コンソールを開く</span><span class="docs-console-short-label" aria-hidden="true">コンソール</span><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-up-right" aria-hidden="true"><path d="M7 7h10v10"></path><path d="M7 17 17 7"></path></svg></a><a href="https://github.com/hazbase" class="docs-github" target="_blank" rel="noreferrer">GitHub<svg xmlns="http://www.w3.org/2000/svg" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-up-right"><path d="M7 7h10v10"></path><path d="M7 17 17 7"></path></svg></a><div class="hb-preferences"><button type="button" id="radix-:R2ut:" aria-haspopup="menu" aria-expanded="false" data-state="closed" class="hb-preference-trigger" aria-label="表示言語: 日本語" title="表示言語"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-globe" aria-hidden="true"><circle cx="12" cy="12" r="10"></circle><path d="M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"></path><path d="M2 12h20"></path></svg><span class="hb-preference-locale">JA</span><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-down hb-preference-chevron" aria-hidden="true"><path d="m6 9 6 6 6-6"></path></svg></button><button type="button" id="radix-:R4ut:" aria-haspopup="menu" aria-expanded="false" data-state="closed" class="hb-preference-trigger" aria-label="テーマ: 端末の設定に合わせる" title="テーマ"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-monitor" aria-hidden="true"><rect width="20" height="14" x="2" y="3" rx="2"></rect><line x1="8" x2="16" y1="21" y2="21"></line><line x1="12" x2="12" y1="17" y2="21"></line></svg><span class="hb-preference-theme">テーマ</span><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-down hb-preference-chevron" aria-hidden="true"><path d="m6 9 6 6 6-6"></path></svg></button></div><button type="button" aria-haspopup="dialog" aria-expanded="false" aria-controls="radix-:R16t:" data-state="closed" class="docs-mobile-toggle" aria-label="目次を開く"><svg xmlns="http://www.w3.org/2000/svg" width="22" height="22" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-menu"><line x1="4" x2="20" y1="12" y2="12"></line><line x1="4" x2="20" y1="6" y2="6"></line><line x1="4" x2="20" y1="18" y2="18"></line></svg></button></div></header><div class="docs-topnav"><a class="" href="/"><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-book-open"><path d="M12 7v14"></path><path d="M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z"></path></svg>ガイド</a><a aria-current="page" class="active" href="/start/day0">クイックスタート</a><a class="" href="/mcp">MCP</a><a class="" href="/reference/sdk"><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-code-xml"><path d="m18 16 4-4-4-4"></path><path d="m6 8-4 4 4 4"></path><path d="m14.5 4-5 16"></path></svg>SDK</a><a class="" href="/reference/http"><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-terminal"><polyline points="4 17 10 11 4 5"></polyline><line x1="12" x2="20" y1="19" y2="19"></line></svg>HTTP API</a><a class="" href="/patterns"><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-blocks"><rect width="7" height="7" x="14" y="3" rx="1"></rect><path d="M10 21V8a1 1 0 0 0-1-1H4a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-5a1 1 0 0 0-1-1H3"></path></svg>実装パターン</a><span>BUILD WITH hazBase</span></div>
11<div class="docs-workarea"><aside class="docs-sidebar"><nav aria-label="ドキュメント"><div class="docs-nav-group"><h2>はじめに</h2><a class="" href="/">概要</a><a class="" href="/evaluate">hazBaseでできること</a><a aria-current="page" class="active" href="/start/day0">クイックスタート</a><a class="" href="/mcp">MCP連携</a><a class="" href="/start/api-access">APIの利用を始める</a></div><div class="docs-nav-group"><h2>基本ガイド</h2><a class="" href="/start/quickstart">最初のAPIリクエスト</a><a class="" href="/start/paths">実装方法を選ぶ</a><a class="" href="/guides/environments">環境と接続情報</a></div><div class="docs-nav-group"><h2>実装ガイド</h2><a class="" href="/guides/authentication">認証とウォレット</a><a class="" href="/guides/token-lifecycle">発行・移転・運用</a></div><div class="docs-nav-group"><h2>リファレンス</h2><a class="" href="/reference/sdk">SDK / パッケージ</a><a class="" href="/reference/http">HTTP API</a><a class="" href="/smart-contracts/contracts">スマートコントラクト</a></div><div class="docs-nav-group"><h2>SDKを調べる</h2><a class="" href="/reference/sdk/kit">@hazbase/kit</a><a class="" href="/reference/sdk/auth">@hazbase/auth</a><a class="" href="/reference/sdk/react">@hazbase/react</a><a class="" href="/reference/sdk/factory">@hazbase/factory</a><a class="" href="/reference/sdk/relayer">@hazbase/relayer</a><a class="" href="/reference/sdk/storage">@hazbase/storage</a><a class="" href="/reference/sdk/zk">@hazbase/zk</a></div><div class="docs-nav-group"><h2>応用と運用</h2><a class="" href="/patterns">用途別の実装パターン</a><a class="" href="/guides/production">導入・運用ガイド</a><a class="" href="/guides/troubleshooting">エラーとトラブル対応</a><a class="" href="/changelog">変更履歴</a></div><div class="docs-nav-group"><h2>背景を理解する</h2><a class="" href="/know-overview">トークンの設計思想</a><a class="" href="/use-cases">ユースケース</a><a class="" href="/reference-implementation">リファレンス実装</a></div><a class="docs-sidebar-link" href="https://lp.hazbase.com/" target="_blank" rel="noreferrer">製品・導入のご案内<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-up-right"><path d="M7 7h10v10"></path><path d="M7 17 17 7"></path></svg></a></nav></aside><main id="docs-main" tabindex="-1" class="flex-1 overflow-auto"><div class="docs-content"><div class="docs-page-content"><!--$--><article class="dev-page"><div class="dev-eyebrow">QUICKSTART</div><h1>はじめてのRWAアプリケーション</h1><p class="dev-lead">サンプルアプリを使って、トークンの発行・割当・移転と保有数の確認を行います。設備・在庫・利用権から用途を選び、名称や発行上限を設定して始められます。</p><div class="day0-selector"><fieldset><legend>サンプルの用途</legend><div class="day0-options"><label class="selected"><input type="radio" name="blueprint" checked=""/><span><strong>設備・ロボット</strong><small>設備に関する権利の発行・割当と運用メモ。</small></span></label><label class=""><input type="radio" name="blueprint"/><span><strong>在庫・物品</strong><small>物品の識別情報に対応する単位の発行・移転。</small></span></label><label class=""><input type="radio" name="blueprint"/><span><strong>利用権・会員資格</strong><small>利用資格の割当と譲渡制限。</small></span></label></div></fieldset><div class="day0-fields"><label>対象名<input maxLength="120" placeholder="配送ロボット A-001" value=""/></label><label>発行上限(整数)<input type="number" min="1" max="1000000" step="1" aria-invalid="false" value="1000"/></label></div><div class="day0-output"><div><small>サンプルが表す権利</small><p>設備に関する契約上の権利を表す検証用単位</p><span class="dev-badge">移転可能</span></div><button class="dev-button"><svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewB
11ox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-download"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path><polyline points="7 10 12 15 17 10"></polyline><line x1="12" x2="12" y1="15" y2="3"></line></svg>設定をダウンロード</button></div></div><section><h2>サンプルアプリを起動する</h2><p>Node.js 22以降を用意し、サンプルをダウンロードして空のフォルダへ展開します。保存したhazbase-brief.jsonを同じフォルダに置いてください。アプリはご利用のPC上で動作し、必要なチェーンとテスト用アカウントを自動で起動します。</p><a href="/downloads/hazbase-day0-kit.tar.gz" class="dev-button" download=""><svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-download"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path><polyline points="7 10 12 15 17 10"></polyline><line x1="12" x2="12" y1="15" y2="3"></line></svg>サンプルアプリをダウンロード</a><div class="relative group rounded-lg overflow-hidden shadow-code border border-border/60"><div class="flex items-center justify-between bg-muted px-4 py-2 border-b border-border"><span class="text-xs font-mono text-muted-foreground">展開先のフォルダで実行</span><button class="inline-flex items-center justify-center gap-2 whitespace-nowrap text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&amp;_svg]:pointer-events-none [&amp;_svg]:size-4 [&amp;_svg]:shrink-0 hover:bg-accent rounded-md h-7 px-2 text-muted-foreground hover:text-foreground" aria-label="Copy code"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-copy h-3.5 w-3.5"><rect width="14" height="14" x="8" y="8" rx="2" ry="2"></rect><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"></path></svg></button></div><div class="flex bg-code-background text-code-foreground text-xs sm:text-sm leading-relaxed"><pre aria-hidden="true" class="select-none shrink-0 text-right py-3 sm:py-4 pl-4 pr-3 text-code-foreground
11/35 border-r border-white/10">1
122</pre><pre class="code-hl min-w-0 flex-1 overflow-x-auto py-3 sm:py-4 px-4"><code class="language-bash"><span class="token function">npm</span> ci
13<span class="token function">npm</span> start -- <span class="token parameter variable">--brief</span> hazbase-brief.json</code></pre></div></div><p>表示された http://127.0.0.1:3400 を開きます。設定ファイルを使わない場合は npm start で設備テンプレートが起動します。初回は依存パッケージの取得が必要です。</p><ol class="day0-steps"><li><b>0<!-- -->1</b><div><strong>資産を定義</strong><p>名称・発行上限・移転可否を設定したコントラクトが起動します。</p></div></li><li><b>0<!-- -->2</b><div><strong>発行・割当</strong><p>参加者へ単位を発行し、残高と取引の記録を確認します。</p></div></li><li><b>0<!-- -->3</b><div><strong>移転・運用記録</strong><p>移転可能なテンプレートでは移転を実行できます。運用メモも追加できます。</p></div></li><li><b>0<!-- -->4</b><div><strong>結果を保存</strong><p>設定、残高、トランザクション、運用メモをJSONとして保存します。</p></div></li></ol></section><section><h2>AIから操作する</h2><p>MCPを設定すると、同じ操作をAIから実行できます。上で選んだ設定を反映したプロンプトを、そのまま利用できます。</p><div class="relative group rounded-lg overflow-hidden shadow-code border border-border/60"><div class="flex items-center justify-between bg-muted px-4 py-2 border-b border-border"><span class="text-xs font-mono text-muted-foreground">AI PROMPT</span><button class="inline-flex items-center justify-center gap-2 whitespace-nowrap text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&amp;_svg]:pointer-events-none [&amp;_svg]:size-4 [&amp;_svg]:shrink-0 hover:bg-accent rounded-md h-7 px-2 text-muted-foreground hover:text-foreground" aria-label="Copy code"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-copy h-3.5 w-3.5"><rect width="14" height="14" x="8" y="8" rx="2" ry="2"></rect><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"></path></svg></button></div><div class="flex bg-code-background text-code-foreground text-xs sm:text-sm leading-relaxed"><pre aria-hidden="true" class="select-none shrink-0 text-right py-3 sm:py-4 pl-4 pr-3 text-code-foreground
13/35 border-r border-white/10">1
142
153
164
175
186
197
208
219
2210
2311
2412</pre><pre class="code-hl min-w-0 flex-1 overflow-x-auto py-3 sm:py-4 px-4"><code class="language-text">次の設定でhazBaseのRWAサンプルアプリを起動してください。
25用途:設備・ロボット
26対象名:配送ロボット A-001
27発行上限:1000単位
28
291. hazbase_get_blueprintとhazbase_get_referenceで構成とSDK仕様を確認してください。
302. hazbase_create_sandboxにblueprint="equipment"、assetNameとunitsを渡してください。
313. operatorへ10単位を発行・割当し、残高を確認してください。
324. 運用メモを追加し、hazbase_export_handoffで結果を取得してください。
335. 画面のURL、実行した操作のトランザクション、実サービスへの組み込みに必要な設定を示してください。
34
35ローカルチェーンの検証であること、運用メモはアプリケーション上の記録であることを明示してください。</code></pre></div></div><a class="dev-link" href="/mcp">MCPの接続手順<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right"><path d="M5 12h14"></path><path d="m12 5 7 7-7 7"></path></svg></a></section><section><h2>実行環境とデータの保存</h2><div class="dev-table-wrap"><table class="dev-table"><thead><tr><th>範囲</th><th>実装</th></tr></thead><tbody><tr><td>発行・割当・移転・残高</td><td>FlexibleTokenと@hazbase/kitを、PC上のEVM(Chain ID 31337)で実行します。チェーンの状態は再起動時にリセットされます。</td></tr><tr><td>資産情報・運用メモ</td><td>アプリケーションのメモリに記録します。再起動すると消えるため、終了前に結果を保存してください。</td></tr><tr><td>実サービスへの組み込み</td><td>サンプルには、実サービス用の認証、永続保存、外部データ連携は含まれていません。契約上の権利との対応や利用チェーンを含め、用途に合わせて設定・実装します。</td></tr></tbody></table></div><div class="dev-callout">このサンプルでは、権利を単位として表し、発行・保有・移転する基本操作を扱います。実物資産の権利や金銭は移転しません。収益分配、ファンド会計、現物の引渡しなどを組み込む場合は、用途別ガイドとSDK仕様を参照できます。</div></section><div class="dev-actions"><a class="dev-link" href="/guides/production">導入・運用ガイド<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right"><path d="M5 12h14"></path><path d="m12 5 7 7-7 7"></path></svg></a><a class="dev-link" href="/patterns">用途別の構成を調べる<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right"><path d="M5 12h14"></path><path d="m12 5 7 7-7 7"></path></svg></a></div><section><h2>実サービスのAPIへ接続する</h2><p>公開情報の参照APIで接続を確認できます。資産の発行・移転などを実サービスへ組み込む際は、各APIの認証・権限と運用条件を確認します。サンプル環境ではAPIの利用申請は不要です。</p><a class="dev-link" href="/start/api-access">APIの利用を始める<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right"><path d="M5 12h14"></path><path d="m12 5 7 7-7 7"></path></svg></a></section></article><!--/$--><footer class="docs-footer"><span>© 2026 IndieSquare Inc.</span><a href="https://lp.hazbase.com/#pilot">技術・導入のご相談<svg xmlns="http://www.w3.org/2000/svg" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-up-right"><path d="M7 7h10v10"></path><path d="M7 17 17 7"></path></svg></a></footer></div></div></main></div></div></div></body></html>

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.