Dnsのロゴ

Dns

組織
hostinger
dns

Hostinger DNS API for zone record management, snapshots, and validation. Use when creating, updating, or deleting DNS records, restoring DNS snapshots, validating zone changes, or resetting DNS to defaults.

概要

公開者hostinger
リポジトリhostinger-agent-skills
スキル名dns
スター
27
フォーク
1
同梱ファイル
1
ライセンスMIT
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 1個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    hostingerがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキルDnsをTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/hostinger/hostinger-agent-skills/tree/main/skills/dns
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/hostinger/hostinger-agent-skills.git /tmp/hostinger-agent-skills
mkdir -p .claude/skills
cp -r /tmp/hostinger-agent-skills/skills/dns .claude/skills/dns
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでDnsを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあると、モデルが自動的にDnsを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Dnsは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、未使用のスキルにはコストがかかりません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

Hostinger DNS

The DNS API enables full management of DNS zone records for domains hosted on Hostinger. You can create, update, delete, validate, and reset DNS records, as well as manage DNS snapshots for backup and restore operations.

Table of Contents

Core Concepts

DNS Records

Standard DNS record types are supported:

TypePurposeExample
AIPv4 address192.168.1.1
AAAAIPv6 address2001:db8::1
CNAMECanonical name aliaswww.example.com.
ALIASANAME/ALIAS recordexample.com.
MXMail exchangemail.example.com.
TXTText recordv=spf1 include:...
NSName serverns1.example.com.
SOAStart of authorityZone authority info
SRVService locator_sip._tcp.example.com.
CAACertificate authority auth0 issue "letsencrypt.org"

Zone Updates

When updating DNS records, the overwrite flag controls behavior:

  • overwrite: true (default) — Replaces existing records matching name and type with the new records
  • overwrite: false — Updates TTL on existing records, appends new records; if no match found, creates them

Snapshots

DNS snapshots capture the state of a domain's DNS zone at a point in time. Use them to restore previous configurations if something goes wrong.

TTL (Time-To-Live)

TTL controls how long DNS resolvers cache a record. Default is 14400 seconds (4 hours). Lower values propagate changes faster but increase DNS query load.

Common Patterns

Get DNS Records for a Domain

bash
curl -X GET "https://developers.hostinger.com/api/dns/v1/zones/example.com" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN"

Python SDK:

python
from hostinger_api import Hostinger

client = Hostinger(api_token="YOUR_API_TOKEN")
records = client.dns.zone.get_dns_records("example.com")
for record in records:
    print(f"{record.type} {record.name} -> {record.content}")

TypeScript SDK:

typescript
import { Hostinger } from "hostinger-api-sdk";

const client = new Hostinger({ apiToken: "YOUR_API_TOKEN" });

const records = await client.dns.zone.getRecords("example.com");
for (const record of records) {
  console.log(`${record.type} ${record.name} -> ${record.content}`);
}

PHP SDK:

php
use Hostinger\Api\HostingerApi;

$client = new HostingerApi('YOUR_API_TOKEN');

$records = $client->dns->zone->getRecords('example.com');
foreach ($records as $record) {
    echo "{$record->type} {$record->name} -> {$record->content}\n";
}

Create/Update DNS Records

bash
# Add an A record for www subdomain
curl -X PUT "https://developers.hostinger.com/api/dns/v1/zones/example.com" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "overwrite": true,
    "zone": [
      {
        "name": "www",
        "type": "A",
        "ttl": 14400,
        "records": [
          { "content": "192.168.1.1" }
        ]
      }
    ]
  }'

# Add MX records for email
curl -X PUT "https://developers.hostinger.com/api/dns/v1/zones/example.com" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "overwrite": true,
    "zone": [
      {
        "name": "@",
        "type": "MX",
        "ttl": 14400,
        "records": [
          { "content": "10 mail1.example.com." },
          { "content": "20 mail2.example.com." }
        ]
      }
    ]
  }'

# Add a TXT record for SPF
curl -X PUT "https://developers.hostinger.com/api/dns/v1/zones/example.com" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "overwrite": false,
    "zone": [
      {
        "name": "@",
        "type": "TXT",
        "ttl": 14400,
        "records": [
          { "content": "v=spf1 include:_spf.google.com ~all" }
        ]
      }
    ]
  }'

Validate Before Updating

bash
# Validate records first (returns 200 if valid, 422 if invalid)
curl -X POST "https://developers.hostinger.com/api/dns/v1/zones/example.com/validate" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "overwrite": true,
    "zone": [
      {
        "name": "www",
        "type": "CNAME",
        "ttl": 14400,
        "records": [
          { "content": "example.com." }
        ]
      }
    ]
  }'

Delete Specific DNS Records

bash
curl -X DELETE "https://developers.hostinger.com/api/dns/v1/zones/example.com" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "filters": [
      { "name": "www", "type": "A" },
      { "name": "old", "type": "CNAME" }
    ]
  }'

Reset DNS to Defaults

bash
curl -X POST "https://developers.hostinger.com/api/dns/v1/zones/example.com/reset" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "sync": true,
    "reset_email_records": false,
    "whitelisted_record_types": ["MX", "TXT"]
  }'

Work with DNS Snapshots

bash
# List available snapshots
curl -X GET "https://developers.hostinger.com/api/dns/v1/snapshots/example.com" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN"

# Get a specific snapshot with contents
curl -X GET "https://developers.hostinger.com/api/dns/v1/snapshots/example.com/42" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN"

# Restore from a snapshot
curl -X POST "https://developers.hostinger.com/api/dns/v1/snapshots/example.com/42/restore" \
  -H "Authorization: Bearer $HOSTINGER_API_TOKEN"

API Reference

Zone Records

MethodEndpointDescription
GET/api/dns/v1/zones/{domain}Get DNS records
PUT/api/dns/v1/zones/{domain}Update DNS records
DELETE/api/dns/v1/zones/{domain}Delete DNS records
POST/api/dns/v1/zones/{domain}/resetReset DNS to defaults
POST/api/dns/v1/zones/{domain}/validateValidate DNS records

Snapshots

MethodEndpointDescription
GET/api/dns/v1/snapshots/{domain}List DNS snapshots
GET/api/dns/v1/snapshots/{domain}/{snapshotId}Get snapshot with contents
POST/api/dns/v1/snapshots/{domain}/{snapshotId}/restoreRestore from snapshot

Best Practices

Record Management

  • Always validate records with the /validate endpoint before applying changes
  • Use overwrite: false when adding records without removing existing ones
  • Use overwrite: true when you want to completely replace records of a given name/type
  • Use @ as the name for root domain records

Safety

  • Take a snapshot (or note existing records) before making bulk changes
  • Use the whitelisted_record_types parameter during reset to preserve email records (MX, TXT)
  • Set reset_email_records: false when resetting if you use third-party email services

TTL

  • Use lower TTL (300-600s) when planning changes for faster propagation
  • Increase TTL (14400s+) for stable records to reduce DNS query load
  • Remember: old cached records persist until the previous TTL expires

Email Records

  • Be careful with MX records — incorrect changes break email delivery
  • SPF, DKIM, and DMARC records are TXT records — don't overwrite them accidentally

Troubleshooting

Records Not Propagating

  • DNS propagation can take up to 48 hours (usually much less)
  • Check the TTL of the old record — resolvers cache for that duration
  • Use dig or nslookup to verify: dig @8.8.8.8 example.com A

422 Validation Error

  • Invalid record content format (e.g., CNAME must end with .)
  • Conflicting records (e.g., CNAME at root with other records)
  • Invalid record type for the operation

Email Stopped Working After DNS Change

  • Check MX records: dig example.com MX
  • Verify SPF TXT record is intact
  • Use the snapshot restore to revert if needed

Delete Not Working as Expected

  • Filters match by name AND type — both must match
  • If multiple records share name/type and you want to delete only some, use the update endpoint instead

See Also

The following deep-dive guide is available in this skill directory:

  • email-dns-setup.md — Complete email DNS setup (MX, SPF, DKIM, DMARC for Google Workspace, Microsoft 365, and Hostinger Email)

References

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Dns」では何ができますか?

Hostinger DNS API for zone record management, snapshots, and validation. Use when creating, updating, or deleting DNS records, restoring DNS snapshots, validating zone changes, or resetting DNS to defaults.

TypingMindでDnsを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Dnsはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにDnsをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/hostinger/hostinger-agent-skills/tree/main/skills/dnsを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Dnsを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストが合致したときにこのスキルを読み込めます。

Dnsは何個のAIモデルで使えますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもDnsを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Dns」は無料ですか?

はい。hostingerがGitHubでMITライセンスの下で公開しています。支払いが必要なのは、利用したトークンに対する、ご自身が契約するAIプロバイダーへの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇