a month ago
Hi all,
We’re automating custom domain provisioning and have run into a mismatch between the public Railway API and the Railway dashboard.
What we’re seeing:
- We add a custom subdomain to a service successfully
- The Railway dashboard shows two DNS records are required:
- a CNAME for the subdomain
- a _railway-verify TXT record for ownership verification
- But the public GraphQL API only returns the CNAME-style DNS record in status.dnsRecords
Example behavior:
- Dashboard shows both CNAME and TXT requirements
- Public GraphQL only returns something like:
- certificateStatus = VALIDATING_OWNERSHIP
- dnsRecords = [{ fqdn: "", requiredValue: ".up.railway.app", status: "REQUIRES_UPDATE" }]
What’s missing from the public API response:
- TXT verification host
- TXT verification token/value
We also noticed that Railway’s internal networking GraphQL used by the dashboard appears to expose fields like:
- verificationDnsHost
- verificationToken
But those are not present in the public API surface we can access with an API token.
Why this matters:
- We can automate the CNAME creation
- but we can’t fully automate ownership verification when Railway requires TXT
- the dashboard clearly knows the TXT details, but the public API doesn’t expose them
Questions:
- Is there a supported public API field or endpoint that returns the TXT verification host/value for custom domains?
- Is status.dnsRecords expected to eventually include the TXT record, or is that not guaranteed?
- Is railway domain --json supposed to expose those verification details?
- Is there a roadmap to expose verificationDnsHost / verificationToken on the public API?
We’re trying to build a reliable automated provisioning flow and want to avoid depending on undocumented internal endpoints if there’s a supported alternative.
Thanks.
2 Replies
Status changed to Awaiting Railway Response Railway • about 1 month ago
a month ago
Hello,
The public API does expose it, but this is graphql, so you need to request those fields in the mutation the same way the dashboard does.
Status changed to Awaiting User Response Railway • about 1 month ago
a month ago
Thanks, not sure what I was doing yesterday but it works now !
Thankyou
Status changed to Awaiting Railway Response Railway • about 1 month ago
Status changed to Solved brody • about 1 month ago