請求書テンプレート
取引日・
- 見本の
会社名・氏名・住所・金額は 架空の ものです。

主な用途
- 月次の
利用料・保守料の 請求 - 販売管理・基幹システムからの
請求書の 一括発行 - PDF の
請求書の メール送付
差し込み項目
API で配列名.項目名 の
| 項目 | 内容 |
|---|---|
number | 請求書番号 |
issued_at | 請求日 |
customer.name | 請求先の |
customer.postal_code | 請求先の |
customer.address | 請求先の |
total | 請求金額 |
subject | 件名 |
due_date | お支払期限 |
issuer.name | 発行者の |
issuer.registration_number | 発行者の |
issuer.postal_code | 発行者の |
issuer.address | 発行者の |
issuer.tel | 発行者の |
issuer.contact | 担当者名 |
items | 明細の |
items.date | 取引年月日 |
items.name | 品目・取引内容 |
items.qty | 数量 |
items.unit | 単位 |
items.price | 単価 |
items.tax_rate | 税率 |
items.amount | 金額 |
tax.rate10.base | 10% 対象の |
tax.rate10.tax | 10% 対象の |
tax.rate8.base | 8% 対象の |
tax.rate8.tax | 8% 対象の |
subtotal | 小計 |
tax_total | 消費税の |
bank.name | 振込先の |
bank.branch | 支店名 |
bank.type | 口座の |
bank.number | 口座番号 |
bank.holder | 口座名義 |
note | 備考 |
使い方
- 管理画面の
[テンプレートを 作成]で、 作成方法に 「ひな型から 作成」 を 選び、 「請求書」 を 選択します。 レイアウトと サンプルデータが プロジェクトに 複製されます。 - テンプレートエディターで、
社名・ロゴ・項目の 配置などを 自社の 書式に 合わせて 編集します。 - API の
POST /v1/rendersにテンプレート名と データを 送信すると、 PDF を 発行します。
テスト環境のsk_test_)create_template のfrom に
API での作成と発行
POST /v1/templates のfrom にinvoice)POST /v1/renders に
1. ひな型からテンプレートを作成
curl https://api.docrelay.jp/v1/templates \
-H "Authorization: Bearer $DOCRELAY_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "name": "請求書", "from": "invoice" }'2. データを送信して PDF を発行
curl https://api.docrelay.jp/v1/renders \
-H "Authorization: Bearer $DOCRELAY_API_KEY" \
-H "Content-Type: application/json" \
-d @invoice.json \
-o invoice.pdfinvoice.json(サンプルデータ。配列は先頭の 1 件、長い文は省略)
{
"template": "請求書",
"format": "pdf",
"data": {
"number": "INV-2026-0412",
"issued_at": "2026-10-31",
"due_date": "2026-11-30",
"subject": "2026 年 10 月分 ご利用料金",
"customer": {
"name": "株式会社見本製作所",
"postal_code": "530-0000",
"address": "大阪府大阪市北区例示町4-5-6 見本ビル3F"
},
"issuer": {
"name": "サンプル商事株式会社",
"registration_number": "T1234567890123",
"postal_code": "100-0000",
"address": "東京都千代田区見本町1-2-3 サンプルビル5F",
"tel": "03-0000-0000",
"contact": "経理部 山田 太郎"
},
"items": [
{
"date": "2026-10-01",
"name": "クラウドサービス利用料(10 月分)",
"qty": 1,
"unit": "式",
"price": 50000,
"tax_rate": "10%",
"amount": 50000
}
],
"tax": {
"rate10": {
"base": 106800,
"tax": 10680
},
"rate8": {
"base": 13200,
"tax": 1056
}
},
"subtotal": 120000,
"tax_total": 11736,
"total": 131736,
"bank": {
"name": "見本銀行",
"branch": "本店営業部",
"type": "普通",
"number": "1234567",
"holder": "サンプルシヨウジ(カ)"
},
"note": "本書の金額は、ご契約のプランと 10 月 1 日〜31 日のご利用実績にもとづきます。…"
}
}


