CURLOPT([key])
Description
Options may be set globally or per channel. Per-channel settings will override global settings. Only HTTP headers are added instead of overriding
Arguments
keycookie- A cookie to send with the request. Multiple cookies are supported.conntimeout- Number of seconds to wait for a connection to succeeddnstimeout- Number of seconds to wait for DNS to be resolvedfollowlocation- Whether or not to follow HTTP 3xx redirects (boolean)ftptext- For FTP URIs, force a text transfer (boolean)ftptimeout- For FTP URIs, number of seconds to wait for a server responseheader- Include header information in the result (boolean)httpauth- Type of authentication method to use. The default is Basic Authentication.basicdigest
httpheader- Add HTTP header. Multiple calls add multiple headers. Setting of any header will remove the default "Content-Type application/x-www-form-urlencoded"httptimeout- For HTTP(S) URIs, number of seconds to wait for a server responsemaxredirs- Maximum number of redirects to follow. The default is -1, which allows for unlimited redirects. This only makes sense when followlocation is also set.proxy- Hostname or IP address to use as a proxy serverproxytype- Type ofproxyhttpsocks4socks5
proxyport- Port number of theproxyproxyuserpwd- A username:password combination to use for authenticating requests through aproxyreferer- Referer URL to use for the requestuseragent- UserAgent string to use for the requestuserpwd- A username:password to use for authentication when the server response to an initial request indicates a 401 status code.ssl_verifypeer- Whether to verify the server certificate against a list of known root certificate authorities (boolean).ssl_verifyhost- Whether to verify the host in the server's TLS certificate. Set to 2 to verify the host, 0 to ignore the host.ssl_cainfo- Path to a file holding one or more certificates to verify the peer's certificate with. Only used whenssl_verifypeeris enabled.ssl_capath- Path to a directory holding multiple CA certificates to verify the peer's certificate with. Only used whenssl_verifypeeris enabled.ssl_cert- Path to a file containing a client certificate. Default format is PEM, and can be changed withssl_certtype.ssl_certtype- The format of thessl_certfile.PEMDER
ssl_key- Path to a file containing a client private key. Default format is PEM, and can be changed withssl_keytypessl_keytype- The format of thessl_keyfile.PEMDERENG
ssl_keypasswd- The passphrase to use thessl_keyfile.hashcompat- Assuming the responses will be inkey1=value1&key2=value2format, reformat the response such that it can be used by theHASHfunction.yesnolegacy- Also translate+to the space character, in violation of current RFC standards.
failurecodes- A comma separated list of HTTP response codes to be treated as errors
User Notes
No notes yet. Be the first to contribute a tip or example.
Contribute a note
Share a tip, gotcha, or practical example. Keep it under 2000 characters. No questions (use the Asterisk community forums for support). Wrap code in backticks.
Related
Functions
CDR()
ABS()
AES_DECRYPT()
AES_ENCRYPT()
AGC()
AGENT()
AMI_CLIENT()
ARRAY()
AST_CONFIG()
AST_SORCERY()
BASE64_DECODE()
BASE64_ENCODE()
BASENAME()
BLACKLIST()
CALENDAR_BUSY()
CALENDAR_EVENT()
CALENDAR_QUERY()
CALENDAR_QUERY_RESULT()
CALENDAR_WRITE()
CALLCOMPLETION()
CALLERID()
CALLERPRES()
CDR_PROP()
CHANNEL()
CHANNELS()
CHANNEL_EXISTS()
CHECKSIPDOMAIN()
CONFBRIDGE()
CONFBRIDGE_CHANNELS()
CONFBRIDGE_INFO()
CONNECTEDLINE()
CSV_QUOTE()
CURL()
CURLOPT()
CUT()
DAHDI_CHANNEL()
DB()
DB_DELETE()
DB_EXISTS()
DB_KEYCOUNT()
DB_KEYS()
DEC()
DELETE()
DENOISE()
DEVICE_STATE()
DIALGROUP()
DIALPLAN_EXISTS()
DIGIT_SUM()
DIRNAME()
DUNDILOOKUP()
DUNDIQUERY()
DUNDIRESULT()
ENUMLOOKUP()
ENUMQUERY()
ENUMRESULT()
ENV()
EVAL()
EVAL_EXTEN()
EVAL_SUB()
EXCEPTION()
EXISTS()
EXPORT()
EXTENSION_STATE()
FAXOPT()
FEATURE()
FEATUREMAP()
FIELDNUM()
FIELDQTY()
FILE()
FILE_COUNT_LINE()
FILE_FORMAT()
FILTER()
FRAME_DROP()
FRAME_TRACE()
GEOLOC_PROFILE()
GLOBAL()
GLOBAL_DELETE()
GLOBAL_EXISTS()
GROUP()
GROUP_COUNT()
GROUP_LIST()
GROUP_MATCH_COUNT()
HANGUPCAUSE()
HANGUPCAUSE_KEYS()
HASH()
HASHKEYS()
HINT()
HOLD_INTERCEPT()
IAXPEER()
IAXVAR()
ICONV()
IF()
IFMODULE()
IFTIME()
IMPORT()
INC()
ISNULL()
JABBER_RECEIVE()
JABBER_STATUS()
JITTERBUFFER()
JSON_DECODE()
KEYPADHASH()
LEN()
LISTFILTER()
LOCAL()
LOCAL_PEEK()
LOCK()
LOG_GROUP()
LTRIM()
MAILBOX_EXISTS()
MASTER_CHANNEL()
MATH()
MAX()
MD5()
MEETME_INFO()
MESSAGE()
MESSAGE_DATA()
MIN()
MINIVMACCOUNT()
MINIVMCOUNTER()
MIXMONITOR()
MUTEAUDIO()
ODBC()
ODBC_FETCH()
PARK_GET_CHANNEL()
PASSTHRU()
PERIODIC_HOOK()
PITCH_SHIFT()
PJSIP_AOR()
PJSIP_CONTACT()
PJSIP_DIAL_CONTACTS()
PJSIP_DTMF_MODE()
PJSIP_ENDPOINT()
PJSIP_HEADER()
PJSIP_HEADERS()
PJSIP_HEADER_PARAM()
PJSIP_INHERITABLE_HEADER()
PJSIP_MEDIA_OFFER()
PJSIP_MOH_PASSTHROUGH()
PJSIP_PARSE_URI()
PJSIP_PARSE_URI_FROM()
PJSIP_RESPONSE_HEADER()
PJSIP_RESPONSE_HEADERS()
PJSIP_SEND_SESSION_REFRESH()
PJSIP_TRANSFER_HANDLING()
POLARITY()
POP()
PP_EACH_EXTENSION()
PP_EACH_USER()
PRESENCE_STATE()
PUSH()
QUEUE_EXISTS()
QUEUE_GET_CHANNEL()
QUEUE_MEMBER()
QUEUE_MEMBER_COUNT()
QUEUE_MEMBER_LIST()
QUEUE_MEMBER_PENALTY()
QUEUE_VARIABLES()
QUEUE_WAITING_COUNT()
QUOTE()
RAND()
REALTIME()
REALTIME_DESTROY()
REALTIME_FIELD()
REALTIME_HASH()
REALTIME_STORE()
RECORDING_INFO()
REDIRECTING()
REGEX()
REPLACE()
RTRIM()
SAYFILES()
SCRAMBLE()
SET()
SHA1()
SHARED()
SHELL()
SHIFT()
SIPPEER()
SIP_HEADER()
SIP_HEADERS()
SMDI_MSG()
SMDI_MSG_RETRIEVE()
SORT()
SPEECH()
SPEECH_ENGINE()
SPEECH_GRAMMAR()
SPEECH_RESULTS_TYPE()
SPEECH_SCORE()
SPEECH_TEXT()
SPRINTF()
SQL_ESC()
SQL_ESC_BACKSLASHES()
SRVQUERY()
SRVRESULT()
STACK_PEEK()
STAT()
STIR_SHAKEN()
STIR_SHAKEN_ATTESTATION()
STRBETWEEN()
STRFTIME()
STRPTIME()
STRREPLACE()
SYSINFO()
TALK_DETECT()
TESTTIME()
TIMEOUT()
TOLOWER()
TONE_DETECT()
TOUPPER()
TRIM()
TRYLOCK()
TXTCIDNAME()
UNLOCK()
UNSHIFT()
URIDECODE()
URIENCODE()
UUID()
VALID_EXTEN()
VARIABLE_EXISTS()
VERSION()
VMCOUNT()
VM_INFO()
VOLUME()