Menu
Tunnels
HTTPS tunnels to an app on your own computer, at your own hostname.
| Operation | Method and path |
|---|---|
| Create a tunnel for a hostname | POST /tunnels |
| The caller's tunnels | GET /tunnels |
| One of the caller's tunnels | GET /tunnels/{id} |
| Replace a tunnel's settings | PATCH /tunnels/{id} |
| Delete a tunnel | DELETE /tunnels/{id} |
| Re-check a tunnel's DNS now | POST /tunnels/{id}/verify-dns |
Create a tunnel for a hostname#
POST /tunnels · operation createTunnel
hostname (a fully qualified name; punycode for an internationalized one), the SSH key as ssh_public_key (one OpenSSH public key line) or ssh_key_id (one of the caller's saved keys, /vps/ssh-keys), exactly one; settings (offline_url: an https URL served while the client is offline; offline_ipns: the IPNS name it came from, kept for display; both passed through as given), region (a placement hint), transport (ssh-v1, the default), manage_dns (default true). Ownership: a hostname under a domain another account registered here is refused 404; when one of the caller's own zones holds the hostname, the record pointing at the tunnel is written in it at once (a CNAME to dns_cname_target below the zone's apex, an A to dns_target at the apex; dns in the answer says what was written; not charged), and a name that already has an A, AAAA or CNAME record there is refused 409 before anything is created; under a domain grant carrying tunnel (another account's registered domain holds the hostname) the tunnel is created for the domain's owner with the caller's key, its record in the owner's zone, its hours billed to the grant's payer (a split payer is refused 400: ask the owner to choose owner or grantee), answered delegated with owner_user_id; any other hostname must be pointed by its owner (A to dns_target, or CNAME to dns_cname_target): the tunnel stays pending-dns until its DNS resolves, which proves control. The answer carries the ready-to-paste ssh_command. Tunnels may be billed by the hour (billing in the answer; 402 insufficient-funds when the credits do not cover the first hour). Cost (credit charges in GET /credits/charges): the per_hour credit charge of recurring.tunnel-hourly is billed every hour while what it creates exists.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | tunnels:write |
| Strong authentication | a session needs an authenticator enrolled and a recent proof of it (a step-up in the last 15 minutes, or totp_code / backup_code in the body); an API key is not asked — see authentication |
| Charged | yes — see the charges below |
| Retry safety | a repeat is refused or changes nothing: a hostname has at most one live tunnel: a repeat is refused 409 hostname-taken |
Credit charges (each a contract of the list of credit charges; the credit charge in force is filled in from the API):
| Contract | Rate | When | Times | Credit charge in force |
|---|---|---|---|---|
recurring.tunnel-hourly | per_hour | every hour while it exists | — | see the credit charges |
Request body (CreateTunnel):
hostname, string, required — a fully qualified name; punycode for an internationalized onessh_public_key, string — one OpenSSH public key line, no options (or ssh_key_id)ssh_key_id, string — one of the caller's saved SSH keys (or ssh_public_key)transport, string —ssh-v1(the default)settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
region, string — a placement hintmanage_dns, boolean — write the record pointing at the node when one of the caller's zones holds the hostname (defaulttrue)
Answer 201 (TunnelCreated): the result
tunnel, object, requiredhostname_verified, boolean — true when the name lies in your own active DNS zone, so no TXT proof is askedtransport, stringhostname, string, requiredclient_connected, boolean, requiredurl, string, requireddns_txt_value, string or null — the value that TXT record must hold (atunnel-verify=<token>)dns_txt_name, string or null — the TXT record that proves the name is yours (_atunnel.<hostname>), when it must prove itself: a name outside your own active DNS zone; null when the zone proved itdns_error, string or nullrestriction, object — on a resource held after a review:suspended(its account is restricted) orblocked(its content or hostname may not be served); the one reason code isabuse-reviewstate, string, required (one ofsuspended,blocked)reason, string, required (must be"abuse-review")decision_id, string or null — the decision on your account that put it in place (GET /auth/account/restrictionslists it; contest it with a support ticket naming it); null when it cannot be told which of your decisions it iscontact, string — the abuse contact address to write to about it
settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
billing, object or null — the hourly billing of a tunnel or an app (null when it is not billed)state, string, required — off: not billed; grace: an hourly charge was refused and it still serves until suspend_at; suspended: not served until the hours are paid; if still unpaid after its retention, deleted no sooner than delete_at: the deletion is announced beforehand (72 hours by default) and, by default, happens only once our team approved it (one ofoff,ok,grace,suspended)paid_through, string or nullunpaid_since, stringsuspend_at, stringsuspended_at, stringdelete_at, string
id, string, requireddns_cname_target, string or null — the node hostname a CNAME points atowner_user_id, string — with delegated: the domain owner's accountdelegated, boolean — true when the caller created it under a domain grant: it is the domain owner'scert_status, string, requiredupdated_at, stringstatus, string, required — the state, except an active tunnel without a connected client readsdegradedmigration, object — only on a tunnel adopted from the previous platform: where it came from and whether the client must change anythingsource, string — where the tunnel came from:previous-platform(must be"previous-platform")imported_at, stringfrom, object — the old connection: ssh_host, ssh_port, ssh_user, port, ssh_command, dns_cname_target, dns_targetto, object — the connection served here: the same keys plus node_ssh_hostclient_unchanged, boolean — true: the client keeps connecting as beforechanged, array of strings — which of ssh_host, ssh_port, ssh_user, port changed
dns_target, string or null — the node's IPv4 an A record points atport, integer, requiredstate, string, required —pending-dns,provisioning,active,failed,deletingdns_ok, boolean, requiredcreated_at, stringssh_command, string or null — the ready-to-paste ssh commandlast_error, string or null — what went wrong last, when anything didnode, one of- variant 1: object
ipv4, string or nullssh_host, stringssh_port, integerssh_user, stringregion, string or null
- variant 2: null
- variant 1: object
dns, object, requiredmanaged, boolean, required — the record pointing at the node was written in the caller's zonezone, string or null, required — the caller's zone holding the hostname (dotted), null when nonerecord, one of, required- variant 1: object
name, string, required — dottedtype, string, required (one ofA,CNAME)data, object, required —{"address"}for an A,{"name"}(dotted) for a CNAME
- variant 2: null
- variant 1: object
reason, string or null, required — why the record is not managed (point the hostname yourself); null when managed (one ofmanage-dns-off,no-zone,dns-not-configured,no-target,null)
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (field hostname, ssh_public_key, ssh_key_id, settings, transport, region or manage_dns) |
| 401 | unauthorized | unauthorized |
| 402 | insufficient-funds | insufficient-funds (the credits do not cover the first hour: top up) |
| 403 | account-suspended, enrolment-required, insufficient-scope, profile-incomplete, step-up-required, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); enrolment-required (a session caller whose account has no authenticator: enrol one first) or step-up-required (a session without a recent step-up: POST /auth/step-up, then retry); account-suspended (the account is restricted while a report about it is reviewed: reading, support tickets and the copy of its data keep working; contact is the address to write to, GET /auth/account/restrictions says more); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found (a hostname under another account's domain; an unknown saved key) |
| 409 | conflict, hostname-taken, tunnel-limit | conflict (the name already has records in the caller's zone), hostname-taken or tunnel-limit |
| 422 | invalid-totp | invalid-totp (a wrong or replayed authenticator code) |
| 429 | rate-limited | rate-limited |
| 451 | hostname-blocked | hostname-blocked (the hostname or content was blocked after a review: reason abuse-review; contest it through a support ticket or contact) |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | capacity-unavailable, charge-not-set, unavailable | capacity-unavailable (no capacity now: try again later), or unavailable (tunnels, or saved SSH keys, are not available now: send ssh_public_key), or charge-not-set (its credit charge is not set yet: nothing was created or charged) |
Example
curl -X POST 'https://api.weird.ro/tunnels' \
-H "Authorization: Bearer $WEIRD_API_KEY" \
-H "Content-Type: application/json" \
-d '{"hostname":"<hostname>"}'With the CLI (weird tunnel):
$ weird tunnel <hostname> <local-port>MCP: weird_tunnels_create.
The caller's tunnels#
GET /tunnels · operation listTunnels
Newest first, with the DNS, certificate and client progress of each; delegated: the tunnels of other accounts on hostnames their domain grants carrying tunnel let the caller manage (each with owner_user_id), which GET, PATCH, DELETE /tunnels/{id} and verify-dns reach too (a change under a sensitive domain refused 403 delegate-blocked). Cost (credit charges in GET /credits/charges): the per_request credit charge of tunnel.reads is charged for each call that answers successfully, after it has answered (a refused or failed call is not charged); the calls are added up and taken from the credits every hour.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | tunnels:read |
| Charged | yes — see the charges below |
| Retry safety | a repeat makes a second one and is charged again: each successful call is charged as one request: a repeat after a lost answer is a second request and is charged again |
Credit charges (each a contract of the list of credit charges; the credit charge in force is filled in from the API):
| Contract | Rate | When | Times | Credit charge in force |
|---|---|---|---|---|
tunnel.reads | per_request | after a successful answer | — | see the credit charges |
Answer 200 (TunnelList): the result
tunnels, array of objects, requiredhostname_verified, boolean — true when the name lies in your own active DNS zone, so no TXT proof is askedtransport, stringhostname, string, requiredclient_connected, boolean, requiredurl, string, requireddns_txt_value, string or null — the value that TXT record must hold (atunnel-verify=<token>)dns_txt_name, string or null — the TXT record that proves the name is yours (_atunnel.<hostname>), when it must prove itself: a name outside your own active DNS zone; null when the zone proved itdns_error, string or nullrestriction, object — on a resource held after a review:suspended(its account is restricted) orblocked(its content or hostname may not be served); the one reason code isabuse-reviewstate, string, required (one ofsuspended,blocked)reason, string, required (must be"abuse-review")decision_id, string or null — the decision on your account that put it in place (GET /auth/account/restrictionslists it; contest it with a support ticket naming it); null when it cannot be told which of your decisions it iscontact, string — the abuse contact address to write to about it
settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
billing, object or null — the hourly billing of a tunnel or an app (null when it is not billed)state, string, required — off: not billed; grace: an hourly charge was refused and it still serves until suspend_at; suspended: not served until the hours are paid; if still unpaid after its retention, deleted no sooner than delete_at: the deletion is announced beforehand (72 hours by default) and, by default, happens only once our team approved it (one ofoff,ok,grace,suspended)paid_through, string or nullunpaid_since, stringsuspend_at, stringsuspended_at, stringdelete_at, string
id, string, requireddns_cname_target, string or null — the node hostname a CNAME points atowner_user_id, string — with delegated: the domain owner's accountdelegated, boolean — true when the caller created it under a domain grant: it is the domain owner'scert_status, string, requiredupdated_at, stringstatus, string, required — the state, except an active tunnel without a connected client readsdegradedmigration, object — only on a tunnel adopted from the previous platform: where it came from and whether the client must change anythingsource, string — where the tunnel came from:previous-platform(must be"previous-platform")imported_at, stringfrom, object — the old connection: ssh_host, ssh_port, ssh_user, port, ssh_command, dns_cname_target, dns_targetto, object — the connection served here: the same keys plus node_ssh_hostclient_unchanged, boolean — true: the client keeps connecting as beforechanged, array of strings — which of ssh_host, ssh_port, ssh_user, port changed
dns_target, string or null — the node's IPv4 an A record points atport, integer, requiredstate, string, required —pending-dns,provisioning,active,failed,deletingdns_ok, boolean, requiredcreated_at, stringssh_command, string or null — the ready-to-paste ssh commandlast_error, string or null — what went wrong last, when anything didnode, one of- variant 1: object
ipv4, string or nullssh_host, stringssh_port, integerssh_user, stringregion, string or null
- variant 2: null
- variant 1: object
count, integer, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | unavailable | unavailable (try again later) |
Example
curl -X GET 'https://api.weird.ro/tunnels' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird tunnels list, weird tunnels stop, weird tunnels delete):
$ weird tunnels list$ weird tunnels stop <hostname|id>$ weird tunnels delete <hostname|id>
MCP: weird_tunnels_list, weird_tunnels_set_offline_folder.
One of the caller's tunnels#
GET /tunnels/{id} · operation getTunnel
state (pending-dns, provisioning, active, failed, deleting) and status (the state, except an active tunnel without a connected client reads degraded). Cost (credit charges in GET /credits/charges): the per_request credit charge of tunnel.reads is charged for each call that answers successfully, after it has answered (a refused or failed call is not charged); the calls are added up and taken from the credits every hour.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | tunnels:read |
| Charged | yes — see the charges below |
| Retry safety | a repeat makes a second one and is charged again: each successful call is charged as one request: a repeat after a lost answer is a second request and is charged again |
Credit charges (each a contract of the list of credit charges; the credit charge in force is filled in from the API):
| Contract | Rate | When | Times | Credit charge in force |
|---|---|---|---|---|
tunnel.reads | per_request | after a successful answer | — | see the credit charges |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Answer 200 (TunnelResult): the result
tunnel, object, requiredhostname_verified, boolean — true when the name lies in your own active DNS zone, so no TXT proof is askedtransport, stringhostname, string, requiredclient_connected, boolean, requiredurl, string, requireddns_txt_value, string or null — the value that TXT record must hold (atunnel-verify=<token>)dns_txt_name, string or null — the TXT record that proves the name is yours (_atunnel.<hostname>), when it must prove itself: a name outside your own active DNS zone; null when the zone proved itdns_error, string or nullrestriction, object — on a resource held after a review:suspended(its account is restricted) orblocked(its content or hostname may not be served); the one reason code isabuse-reviewstate, string, required (one ofsuspended,blocked)reason, string, required (must be"abuse-review")decision_id, string or null — the decision on your account that put it in place (GET /auth/account/restrictionslists it; contest it with a support ticket naming it); null when it cannot be told which of your decisions it iscontact, string — the abuse contact address to write to about it
settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
billing, object or null — the hourly billing of a tunnel or an app (null when it is not billed)state, string, required — off: not billed; grace: an hourly charge was refused and it still serves until suspend_at; suspended: not served until the hours are paid; if still unpaid after its retention, deleted no sooner than delete_at: the deletion is announced beforehand (72 hours by default) and, by default, happens only once our team approved it (one ofoff,ok,grace,suspended)paid_through, string or nullunpaid_since, stringsuspend_at, stringsuspended_at, stringdelete_at, string
id, string, requireddns_cname_target, string or null — the node hostname a CNAME points atowner_user_id, string — with delegated: the domain owner's accountdelegated, boolean — true when the caller created it under a domain grant: it is the domain owner'scert_status, string, requiredupdated_at, stringstatus, string, required — the state, except an active tunnel without a connected client readsdegradedmigration, object — only on a tunnel adopted from the previous platform: where it came from and whether the client must change anythingsource, string — where the tunnel came from:previous-platform(must be"previous-platform")imported_at, stringfrom, object — the old connection: ssh_host, ssh_port, ssh_user, port, ssh_command, dns_cname_target, dns_targetto, object — the connection served here: the same keys plus node_ssh_hostclient_unchanged, boolean — true: the client keeps connecting as beforechanged, array of strings — which of ssh_host, ssh_port, ssh_user, port changed
dns_target, string or null — the node's IPv4 an A record points atport, integer, requiredstate, string, required —pending-dns,provisioning,active,failed,deletingdns_ok, boolean, requiredcreated_at, stringssh_command, string or null — the ready-to-paste ssh commandlast_error, string or null — what went wrong last, when anything didnode, one of- variant 1: object
ipv4, string or nullssh_host, stringssh_port, integerssh_user, stringregion, string or null
- variant 2: null
- variant 1: object
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found (an unknown tunnel, another customer's alike) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | unavailable | unavailable (try again later) |
Example
curl -X GET 'https://api.weird.ro/tunnels/{id}' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird tunnels get, weird tunnel):
$ weird tunnels get <hostname|id>$ weird tunnel <hostname> <local-port>
MCP: weird_tunnels_get.
Replace a tunnel's settings#
PATCH /tunnels/{id} · operation updateTunnel
settings, the whole object: a key left out is cleared ({} clears both). Refused while the tunnel is deleting. Send the previous settings the same way to undo it. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | tunnels:write |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Request body (UpdateTunnel):
settings, object, requiredoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
Answer 200 (TunnelResult): the result
tunnel, object, requiredhostname_verified, boolean — true when the name lies in your own active DNS zone, so no TXT proof is askedtransport, stringhostname, string, requiredclient_connected, boolean, requiredurl, string, requireddns_txt_value, string or null — the value that TXT record must hold (atunnel-verify=<token>)dns_txt_name, string or null — the TXT record that proves the name is yours (_atunnel.<hostname>), when it must prove itself: a name outside your own active DNS zone; null when the zone proved itdns_error, string or nullrestriction, object — on a resource held after a review:suspended(its account is restricted) orblocked(its content or hostname may not be served); the one reason code isabuse-reviewstate, string, required (one ofsuspended,blocked)reason, string, required (must be"abuse-review")decision_id, string or null — the decision on your account that put it in place (GET /auth/account/restrictionslists it; contest it with a support ticket naming it); null when it cannot be told which of your decisions it iscontact, string — the abuse contact address to write to about it
settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
billing, object or null — the hourly billing of a tunnel or an app (null when it is not billed)state, string, required — off: not billed; grace: an hourly charge was refused and it still serves until suspend_at; suspended: not served until the hours are paid; if still unpaid after its retention, deleted no sooner than delete_at: the deletion is announced beforehand (72 hours by default) and, by default, happens only once our team approved it (one ofoff,ok,grace,suspended)paid_through, string or nullunpaid_since, stringsuspend_at, stringsuspended_at, stringdelete_at, string
id, string, requireddns_cname_target, string or null — the node hostname a CNAME points atowner_user_id, string — with delegated: the domain owner's accountdelegated, boolean — true when the caller created it under a domain grant: it is the domain owner'scert_status, string, requiredupdated_at, stringstatus, string, required — the state, except an active tunnel without a connected client readsdegradedmigration, object — only on a tunnel adopted from the previous platform: where it came from and whether the client must change anythingsource, string — where the tunnel came from:previous-platform(must be"previous-platform")imported_at, stringfrom, object — the old connection: ssh_host, ssh_port, ssh_user, port, ssh_command, dns_cname_target, dns_targetto, object — the connection served here: the same keys plus node_ssh_hostclient_unchanged, boolean — true: the client keeps connecting as beforechanged, array of strings — which of ssh_host, ssh_port, ssh_user, port changed
dns_target, string or null — the node's IPv4 an A record points atport, integer, requiredstate, string, required —pending-dns,provisioning,active,failed,deletingdns_ok, boolean, requiredcreated_at, stringssh_command, string or null — the ready-to-paste ssh commandlast_error, string or null — what went wrong last, when anything didnode, one of- variant 1: object
ipv4, string or nullssh_host, stringssh_port, integerssh_user, stringregion, string or null
- variant 2: null
- variant 1: object
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (field settings) |
| 401 | unauthorized | unauthorized |
| 403 | account-suspended, insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); account-suspended (the account is restricted while a report about it is reviewed: reading, support tickets and the copy of its data keep working; contact is the address to write to, GET /auth/account/restrictions says more); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found |
| 409 | conflict | conflict (deleting) |
| 429 | rate-limited | rate-limited |
| 451 | hostname-blocked | hostname-blocked (the hostname or content was blocked after a review: reason abuse-review; contest it through a support ticket or contact) |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | unavailable | unavailable (try again later) |
Example
curl -X PATCH 'https://api.weird.ro/tunnels/{id}' \
-H "Authorization: Bearer $WEIRD_API_KEY" \
-H "Content-Type: application/json" \
-d '{"settings":{}}'With the CLI (weird tunnels update):
$ weird tunnels update <hostname|id>MCP: weird_tunnels_update, weird_tunnels_set_offline_folder.
Delete a tunnel#
DELETE /tunnels/{id} · operation deleteTunnel
A tunnel that never went live is deleted at once; any other moves to deleting until it is torn down. The record written for its hostname is removed from the caller's zone where unchanged (dns.removed). Safe to repeat while deleting. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | tunnels:write |
| Strong authentication | a session needs an authenticator enrolled and a recent proof of it (a step-up in the last 15 minutes, or totp_code / backup_code in the body); an API key is not asked — see authentication |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Answer 200 (TunnelDeleted): the result
tunnel, object, requiredhostname_verified, boolean — true when the name lies in your own active DNS zone, so no TXT proof is askedtransport, stringhostname, string, requiredclient_connected, boolean, requiredurl, string, requireddns_txt_value, string or null — the value that TXT record must hold (atunnel-verify=<token>)dns_txt_name, string or null — the TXT record that proves the name is yours (_atunnel.<hostname>), when it must prove itself: a name outside your own active DNS zone; null when the zone proved itdns_error, string or nullrestriction, object — on a resource held after a review:suspended(its account is restricted) orblocked(its content or hostname may not be served); the one reason code isabuse-reviewstate, string, required (one ofsuspended,blocked)reason, string, required (must be"abuse-review")decision_id, string or null — the decision on your account that put it in place (GET /auth/account/restrictionslists it; contest it with a support ticket naming it); null when it cannot be told which of your decisions it iscontact, string — the abuse contact address to write to about it
settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
billing, object or null — the hourly billing of a tunnel or an app (null when it is not billed)state, string, required — off: not billed; grace: an hourly charge was refused and it still serves until suspend_at; suspended: not served until the hours are paid; if still unpaid after its retention, deleted no sooner than delete_at: the deletion is announced beforehand (72 hours by default) and, by default, happens only once our team approved it (one ofoff,ok,grace,suspended)paid_through, string or nullunpaid_since, stringsuspend_at, stringsuspended_at, stringdelete_at, string
id, string, requireddns_cname_target, string or null — the node hostname a CNAME points atowner_user_id, string — with delegated: the domain owner's accountdelegated, boolean — true when the caller created it under a domain grant: it is the domain owner'scert_status, string, requiredupdated_at, stringstatus, string, required — the state, except an active tunnel without a connected client readsdegradedmigration, object — only on a tunnel adopted from the previous platform: where it came from and whether the client must change anythingsource, string — where the tunnel came from:previous-platform(must be"previous-platform")imported_at, stringfrom, object — the old connection: ssh_host, ssh_port, ssh_user, port, ssh_command, dns_cname_target, dns_targetto, object — the connection served here: the same keys plus node_ssh_hostclient_unchanged, boolean — true: the client keeps connecting as beforechanged, array of strings — which of ssh_host, ssh_port, ssh_user, port changed
dns_target, string or null — the node's IPv4 an A record points atport, integer, requiredstate, string, required —pending-dns,provisioning,active,failed,deletingdns_ok, boolean, requiredcreated_at, stringssh_command, string or null — the ready-to-paste ssh commandlast_error, string or null — what went wrong last, when anything didnode, one of- variant 1: object
ipv4, string or nullssh_host, stringssh_port, integerssh_user, stringregion, string or null
- variant 2: null
- variant 1: object
dns, object, requiredremoved, array of objects, required — the automatic record removed from the caller's zonename, string, required — dottedtype, string, required (one ofA,CNAME)data, object, required —{"address"}for an A,{"name"}(dotted) for a CNAME
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | account-suspended, enrolment-required, insufficient-scope, profile-incomplete, step-up-required, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); enrolment-required (a session caller whose account has no authenticator: enrol one first) or step-up-required (a session without a recent step-up: POST /auth/step-up, then retry); account-suspended (the account is restricted while a report about it is reviewed: reading, support tickets and the copy of its data keep working; contact is the address to write to, GET /auth/account/restrictions says more); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found |
| 422 | invalid-totp | invalid-totp (a wrong or replayed authenticator code) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | unavailable | unavailable (try again later) |
Example
curl -X DELETE 'https://api.weird.ro/tunnels/{id}' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird tunnels delete):
$ weird tunnels delete <hostname|id>MCP: weird_tunnels_delete.
Re-check a tunnel's DNS now#
POST /tunnels/{id}/verify-dns · operation verifyTunnelDns
No body. A pending-dns tunnel whose DNS now resolves moves on to provisioning; a failed tunnel retries its certificate. Safe to repeat. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | tunnels:write |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Answer 200 (TunnelResult): the result
tunnel, object, requiredhostname_verified, boolean — true when the name lies in your own active DNS zone, so no TXT proof is askedtransport, stringhostname, string, requiredclient_connected, boolean, requiredurl, string, requireddns_txt_value, string or null — the value that TXT record must hold (atunnel-verify=<token>)dns_txt_name, string or null — the TXT record that proves the name is yours (_atunnel.<hostname>), when it must prove itself: a name outside your own active DNS zone; null when the zone proved itdns_error, string or nullrestriction, object — on a resource held after a review:suspended(its account is restricted) orblocked(its content or hostname may not be served); the one reason code isabuse-reviewstate, string, required (one ofsuspended,blocked)reason, string, required (must be"abuse-review")decision_id, string or null — the decision on your account that put it in place (GET /auth/account/restrictionslists it; contest it with a support ticket naming it); null when it cannot be told which of your decisions it iscontact, string — the abuse contact address to write to about it
settings, objectoffline_url, string — an https URL the node serves while the client is offline (a page, or a site as a tar)offline_ipns, string — the IPNS name offline_url came from, kept for display (not resolved)
billing, object or null — the hourly billing of a tunnel or an app (null when it is not billed)state, string, required — off: not billed; grace: an hourly charge was refused and it still serves until suspend_at; suspended: not served until the hours are paid; if still unpaid after its retention, deleted no sooner than delete_at: the deletion is announced beforehand (72 hours by default) and, by default, happens only once our team approved it (one ofoff,ok,grace,suspended)paid_through, string or nullunpaid_since, stringsuspend_at, stringsuspended_at, stringdelete_at, string
id, string, requireddns_cname_target, string or null — the node hostname a CNAME points atowner_user_id, string — with delegated: the domain owner's accountdelegated, boolean — true when the caller created it under a domain grant: it is the domain owner'scert_status, string, requiredupdated_at, stringstatus, string, required — the state, except an active tunnel without a connected client readsdegradedmigration, object — only on a tunnel adopted from the previous platform: where it came from and whether the client must change anythingsource, string — where the tunnel came from:previous-platform(must be"previous-platform")imported_at, stringfrom, object — the old connection: ssh_host, ssh_port, ssh_user, port, ssh_command, dns_cname_target, dns_targetto, object — the connection served here: the same keys plus node_ssh_hostclient_unchanged, boolean — true: the client keeps connecting as beforechanged, array of strings — which of ssh_host, ssh_port, ssh_user, port changed
dns_target, string or null — the node's IPv4 an A record points atport, integer, requiredstate, string, required —pending-dns,provisioning,active,failed,deletingdns_ok, boolean, requiredcreated_at, stringssh_command, string or null — the ready-to-paste ssh commandlast_error, string or null — what went wrong last, when anything didnode, one of- variant 1: object
ipv4, string or nullssh_host, stringssh_port, integerssh_user, stringregion, string or null
- variant 2: null
- variant 1: object
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | account-suspended, insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); account-suspended (the account is restricted while a report about it is reviewed: reading, support tickets and the copy of its data keep working; contact is the address to write to, GET /auth/account/restrictions says more); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found (deleting included) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | unavailable | unavailable (try again later) |
Example
curl -X POST 'https://api.weird.ro/tunnels/{id}/verify-dns' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird tunnels verify-dns, weird tunnel):
$ weird tunnels verify-dns <hostname|id>$ weird tunnel <hostname> <local-port>
MCP: weird_tunnels_verify_dns.
This page is generated from the API's public document; it changes when the document does.