({{, (RefLink[$UserAgentString, paclet:ref/$UserAgentString]) 
gives the user agent string from an HTTP request that initiated the current evaluation.}})

OpenersNotesSection(Spacer1)Details

If the current evaluation was not initiated by an HTTP request, (RefLink[$UserAgentString, paclet:ref/$UserAgentString]) is (RefLink[None, paclet:ref/None]).

(RefLink[$UserAgentString, paclet:ref/$UserAgentString]) is set not only for direct web calls such as those through an API, but also for interactive sessions that occur in the Wolfram Cloud Platform.

OpenersPrimaryExamplesSection(Spacer1)Examples  (1)

OpenersExampleSection0(Spacer1)Basic Examples  (1)

Deploy an API function that returns the user agent string:

obj=CloudDeploy[APIFunction[{},$UserAgentString&]]

Get the user agent string of the originator of this request:

Import[First[obj]]

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[HTTPRequestData, paclet:ref/HTTPRequestData])  ▪  (RefLink[$RequesterAddress, paclet:ref/$RequesterAddress])  ▪  (RefLink[$CloudEvaluation, paclet:ref/$CloudEvaluation])  ▪  (RefLink[$EvaluationCloudObject, paclet:ref/$EvaluationCloudObject])  ▪  (RefLink[CloudLoggingData, paclet:ref/CloudLoggingData])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Cloud Execution Metadata, paclet:guide/CloudExecutionMetadata])}, {▪(RefLinkPlain[Cloud Functions & Deployment, paclet:guide/CloudFunctionsAndDeployment])}, {▪(RefLinkPlain[Creating Form Interfaces & Apps, paclet:guide/CreatingFormsAndApps])}, {▪(RefLinkPlain[Creating Instant APIs, paclet:guide/CreatingAnInstantAPI])}, {▪(RefLinkPlain[HTTP Requests & Responses, paclet:guide/HTTPRequestsAndResponses])}, {▪(RefLinkPlain[Internet and Computer Systems Data, paclet:guide/InternetAndWebRelatedData])}})}})