- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
Description
Gets the agent definition and metadata for an agent.
URL parameters
Name | Required | Type | Description |
---|---|---|---|
AgentID | True | numeric | Unique identifier of the agent. |
Version (Optional) | True | numeric | The version number of the definition that will be retrieved. If omitted, the latest version will be requested. |
Responses
Name | Type | Description |
---|---|---|
Result | string | Success if the operation was successful. |
AgentID | numeric | Unique identifier of the agent. |
CollectionID | numeric | Unique identifier of the collection. |
Description | string | Description of the agent. |
Domain | string | Starting domain of the agent. |
Definition | string | The XML definition of the agent. |
Version | numeric | The agent version that was returned with in the Definition property of the response. Any number less than this can be requested directly. |
Sample request
curl -X GET "https://api.mozenda.com/rest?WebServiceKey=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX&Service=Mozenda10&Operation=Agent.Get&Version=5&AgentID=152042"
Sample responses
XML
<?xml version="1.0" encoding="utf-8"?>
<AgentGetResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Result>Success</Result>
<AgentID>152042</AgentID>
<Name>M-ItemGet-Test</Name>
<IsLocked>False</IsLocked>
<CollectionID>131807</CollectionID>
<Description />
<Status>Ready</Status>
<Domain>mozenda.com</Domain>
<Definition><![CDATA[<!-- Copyright (C) 2024 Mozenda, Inc. All rights reserved. -->
<Agent>
<Version>1.0o</Version>
<IeVersion>11.3636</IeVersion>
<BrowserType>Chromium</BrowserType>
<BrowserVersion>120.0.6099.109</BrowserVersion>
<TemplateID>0</TemplateID>
<RequestBlockLevel>-1</RequestBlockLevel>
<AgentDefinition>
<!--- - - - - - - - Changes - - - - - - - - -->
<ChangeList>
<Change>
<DateTime>2024-01-17 16:10:18</DateTime>
<UserID>0</UserID>
<UserName>Curtis, Jon</UserName>
<Email>jon@email.com</Email>
<RevisionNumber>0</RevisionNumber>
</Change>
</ChangeList>
<!--- - - - - - - - Browser Proxy Bypass Expressions - - - - - - - - -->
<BrowserProxyBypassExpressionList>
<BrowserProxyBypassExpression>regex:(?i)(mozenda\\.com|doubleclick\\.net|sitescout\\.com|moatads\\.com|mookie\\.com|adrta\\.com|adsafeprotected\\.com|mookie1\\.com)</BrowserProxyBypassExpression>
<BrowserProxyBypassExpression>regex:(?i)(\\.css|\\.js|\\.font)$</BrowserProxyBypassExpression>
<BrowserProxyBypassExpression>regex:(?i)(\\.png|\\.gif|\\.jpg|\\.tiff|\\.bmp|\\.webp|\\.ico|\\.svg)$</BrowserProxyBypassExpression>
<BrowserProxyBypassExpression>regex:(?i)(\\.mpg|\\.mpeg|\\.swf|\\.flv|\\.ogg|\\.webm|\\.mp4|\\.mp3|\\.wav)$</BrowserProxyBypassExpression>
<BrowserProxyBypassExpression>regex:(?i)(gstatic\\.com|googleapis\\.com|googlesyndication\\.com|google-analytics\\.com)</BrowserProxyBypassExpression>
</BrowserProxyBypassExpressionList>
<!--- - - - - - - - Actions - - - - - - - - -->
<ActionList>
<Action>
<ActionID>Action-0</ActionID>
<ActionType>LoadPage</ActionType>
<Page>0</Page>
<IsCaptureOptional>False</IsCaptureOptional>
<DestinationPage>1</DestinationPage>
<TopLevelNav>True</TopLevelNav>
<TopLevelNavCount>1</TopLevelNavCount>
<PageUrl>http://web1.mozenda.com/builderwelcomechromium</PageUrl>
</Action>
<!-- Page 1 -->
<Action>
<ActionID>Action-1</ActionID>
<ActionType>PagePlaceHolder</ActionType>
<Page>1</Page>
<IsCaptureOptional>False</IsCaptureOptional>
<LoadUrl>http://web1.mozenda.com/builderwelcomechromium</LoadUrl>
<BaseUrl>http://web1.mozenda.com/builderwelcomechromium</BaseUrl>
<CaptureScreenShot>False</CaptureScreenShot>
</Action>
</ActionList>
</AgentDefinition>
</Agent>]]></Definition>
<Version>5</Version>
</AgentGetResponse>
JSON (add &ResponseFormat=JSON
)
{
"AgentID": 152042,
"Name": "M-ItemGet-Test",
"IsLocked": "False",
"CollectionID": 131807,
"Description": "",
"Status": "Ready",
"Domain": "mozenda.com",
"Definition": {
"__cdata": "<!-- Copyright (C) 2024 Mozenda, Inc. All rights reserved. -->\n\n<Agent>\n <Version>1.0o</Version>\n <IeVersion>11.3636</IeVersion>\n <BrowserType>Chromium</BrowserType>\n <BrowserVersion>120.0.6099.109</BrowserVersion>\n <TemplateID>0</TemplateID>\n <RequestBlockLevel>-1</RequestBlockLevel>\n <AgentDefinition>\n\n <!--- - - - - - - - Changes - - - - - - - - -->\n\n <ChangeList>\n\n <Change>\n <DateTime>2024-01-17 16:10:18</DateTime>\n <UserID>0</UserID>\n <UserName>Curtis, Jon</UserName>\n <Email>support@mozenda.com</Email>\n <RevisionNumber>0</RevisionNumber>\n </Change>\n\n </ChangeList>\n\n <!--- - - - - - - - Browser Proxy Bypass Expressions - - - - - - - - -->\n\n <BrowserProxyBypassExpressionList>\n <BrowserProxyBypassExpression>regex:(?i)(mozenda\\\\.com|doubleclick\\\\.net|sitescout\\\\.com|moatads\\\\.com|mookie\\\\.com|adrta\\\\.com|adsafeprotected\\\\.com|mookie1\\\\.com)</BrowserProxyBypassExpression>\n <BrowserProxyBypassExpression>regex:(?i)(\\\\.css|\\\\.js|\\\\.font)$</BrowserProxyBypassExpression>\n <BrowserProxyBypassExpression>regex:(?i)(\\\\.png|\\\\.gif|\\\\.jpg|\\\\.tiff|\\\\.bmp|\\\\.webp|\\\\.ico|\\\\.svg)$</BrowserProxyBypassExpression>\n <BrowserProxyBypassExpression>regex:(?i)(\\\\.mpg|\\\\.mpeg|\\\\.swf|\\\\.flv|\\\\.ogg|\\\\.webm|\\\\.mp4|\\\\.mp3|\\\\.wav)$</BrowserProxyBypassExpression>\n <BrowserProxyBypassExpression>regex:(?i)(gstatic\\\\.com|googleapis\\\\.com|googlesyndication\\\\.com|google-analytics\\\\.com)</BrowserProxyBypassExpression>\n </BrowserProxyBypassExpressionList>\n <!--- - - - - - - - Actions - - - - - - - - -->\n\n <ActionList>\n\n <Action>\n <ActionID>Action-0</ActionID>\n <ActionType>LoadPage</ActionType>\n <Page>0</Page>\n <IsCaptureOptional>False</IsCaptureOptional>\n <DestinationPage>1</DestinationPage>\n <TopLevelNav>True</TopLevelNav>\n <TopLevelNavCount>1</TopLevelNavCount>\n <PageUrl>http://web1.mozenda.com/builderwelcomechromium</PageUrl>\n </Action>\n\n <!-- Page 1 -->\n\n <Action>\n <ActionID>Action-1</ActionID>\n <ActionType>PagePlaceHolder</ActionType>\n <Page>1</Page>\n <IsCaptureOptional>False</IsCaptureOptional>\n <LoadUrl>http://web1.mozenda.com/builderwelcomechromium</LoadUrl>\n <BaseUrl>http://web1.mozenda.com/builderwelcomechromium</BaseUrl>\n <CaptureScreenShot>False</CaptureScreenShot>\n </Action>\n </ActionList>\n </AgentDefinition>\n</Agent>"
},
"Version": 5
}
Was this article helpful?