Skip to main content
resolveSrv - node__dns--promises.d.ts - Node documentation
function resolveSrv

Usage in Deno

```typescript import { resolveSrv } from "node:node__dns--promises.d.ts"; ```
resolveSrv(hostname: string): Promise<SrvRecord[]>
Uses the DNS protocol to resolve service records (`SRV` records) for the `hostname`. On success, the `Promise` is resolved with an array of objects with the following properties: * `priority` * `weight` * `port` * `name` ```js { priority: 10, weight: 5, port: 21223, name: 'service.example.com' } ```

Parameters

hostname: string

Return Type

Promise<SrvRecord[]>