CURL.SetOptionDOHURL
--------------------

Provides the DNS-over-HTTPS URL.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [CURL](component_CURL.md) | [8.5](newinversion85.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "CURL.SetOptionDOHURL"; curl; Value ) 

**MBS**( **"CURL.SetOptionDOHURL";** /\* Provides the DNS-over-HTTPS URL. \*/  
**$curl**; /\* The CURL session handle. \*/   
**$Value**) /\* The new URL. \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| curl | The CURL session handle. | $curl |
| Value | The new URL. |  |

### Result

Returns OK or error.

### Description

Provides the DNS-over-HTTPS URL.  
Pass in a string to a URL for the DOH server to use for name resolving. The parameter should be URL-encoded in the following format: "https://host:port/path". It MUST specify a HTTPS URL.  
  
libcurl doesn't validate the syntax or use this variable until the transfer is issued. Even if you set a crazy value here, CURL.SetOptionDOHURL will still return OK.  
  
curl sends POST requests to the given DNS-over-HTTPS URL.  
  
To find the DOH server itself, which might be specified using a name, libcurl will use the default name lookup function. You can bootstrap that by providing the address for the DOH server with [CURL.SetOptionResolve](CURLSetOptionResolve.md).  
  
Disable DOH use again by setting this option to "".  
See also [DOH\_URL](https://curl.haxx.se/libcurl/c/CURLOPT_DOH_URL.html) option in CURL manual.

### See also

- [CURL.GetOptionURL](CURLGetOptionURL.md)
- [CURL.SetOptionCRLF](CURLSetOptionCRLF.md)
- [CURL.SetOptionNetRC](CURLSetOptionNetRC.md)
- [CURL.SetOptionResolve](CURLSetOptionResolve.md)
- [CURL.SetOptionURL](CURLSetOptionURL.md)
- [CURL.SetOptionUseSSL](CURLSetOptionUseSSL.md)

### Release notes

- **Version 8.5**
    - Added [CURL.SetOptionDOHURL](http://www.mbsplugins.eu/CURLSetOptionDOHURL.shtml), [CURL.SetOptionUpkeepIntervalMS](http://www.mbsplugins.eu/CURLSetOptionUpkeepIntervalMS.shtml), [CURL.SetOptionUploadBufferSize](http://www.mbsplugins.eu/CURLSetOptionUploadBufferSize.shtml) and [CURL.Upkeep](http://www.mbsplugins.eu/CURLUpkeep.shtml).

### Blog Entries

- [MBS FileMaker Plugin, version 8.5pr5](https://www.mbsplugins.de/archive/2018-11-02/MBS_FileMaker_Plugin_version_8/monkeybreadsoftware_blog_filemaker)

Created 31st October 2018 , last changed 31st October 2018

  
[CURL.SetOptionDOHSSLVerifyStatus](CURLSetOptionDOHSSLVerifyStatus.md) - [CURL.SetOptionDefaultProtocol](CURLSetOptionDefaultProtocol.md)

[HTML Version](CURLSetOptionDOHURL.shtml)