Update DNS Record
update_dns_recordChange an existing DNS record's type, content, TTL, or priority using its record_id. Alerts you if the domain's nameservers aren't Porkbun's.
Instructions
Update an existing DNS record by its numeric record_id (obtained from list_dns_records). All fields except record_id and domain are optional — pass only the ones you want to change. Idempotent: applying the same update twice is a no-op.
Check warnings in the response and pass it on. Porkbun keeps a DNS zone for every domain in the account whether or not the domain is delegated to Porkbun's nameservers, so this write succeeds either way. If the domain points somewhere else, the response is still SUCCESS but carries a warnings string naming the nameservers that actually answer — the record exists and nothing resolves differently. Do not report plain success in that case: either make the change at the provider that runs those nameservers, or offer update_nameservers to point the domain at Porkbun.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ttl | No | New TTL in seconds. | |
| name | No | New subdomain prefix (empty string = apex). | |
| prio | No | New priority (MX/SRV only). | |
| type | No | New record type (rarely changed). | |
| domain | Yes | Domain the record belongs to, e.g. `example.com` | |
| content | No | New record value. | |
| dry_run | No | If true, validate only — confirms the record exists and is editable, returns wouldSucceed without changing it. | |
| record_id | Yes | Numeric record ID (as a string). Get this from `list_dns_records`. |