> For the complete documentation index, see [llms.txt](https://developer.magtek.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.magtek.com/hardware/card-readers/mms-dyna-devices/dynaflex-ii-go/documents/user-manuals/magneflex-browser-developer-tool-programmers-reference-web-api/magneflex-browser-web-api-resources/requestsendextendedcommand.md).

# requestSendExtendedCommand

This query string sends an extended command to the device and returns the raw response from the device.

{% code overflow="wrap" %}

```
?operation= 
&httpMethod= 
&closeDeviceAfter= 
&readerArgument= 
&destinationURL= 
&requestLocation= 
&passInData=
```

{% endcode %}

<table data-header-hidden><thead><tr><th width="166.727294921875" valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Parameter</td><td valign="top">Description</td></tr><tr><td valign="top">operation</td><td valign="top">Operation to request from MagneFlex. Use: requestSendExtendedCommand</td></tr><tr><td valign="top">httpMethod</td><td valign="top"><p>HTTP method to be used for the HTTP postback from MagneFlex. Use:</p><p>GET - returns the response data in the form of a query string. POST – recommended for EVM related transactions to accommodate limits on query string lengths.</p></td></tr><tr><td valign="top">closeDeviceAfter</td><td valign="top"><p>Flag to close the device after the request. Use:</p><p>true – close device</p><p>false – do not close the device</p></td></tr><tr><td valign="top">readerArgument</td><td valign="top">Extended command to send to reader.</td></tr><tr><td valign="top">destinationURL</td><td valign="top">MagneFlex will send the postback to this URL.</td></tr><tr><td valign="top">requestLocation</td><td valign="top"><p>Flag to send GPS location of the device from which Magneflex (iOS only) is hosted.</p><p>Use:</p><p>true – send location</p><p>false – do not send location</p></td></tr><tr><td valign="top">passInData</td><td valign="top">Optional data to send to MagneFlex. This data will be passed back to the web app.</td></tr></tbody></table>

Each input parameter supplied in the request is delimited by an ampersand character ‘&’, and the value for a parameter begins after an equal character ‘=’. Where ever a parameter contains multiple values, each are delimited by a comma character ‘,’.

**Example query:**

{% code overflow="wrap" %}

```
https://192.168.10.100/magneflexdemo/default.aspx? 
operation=requestSendExtendedCommand 
&httpMethod=GET
&closeDeviceAfter=true 
&readerArgument=03060003010F00
&destinationURL= https://192.168.10.100/magneflexdemo/cardpostback.aspx 
&requestLocation=false
&passInData=
```

{% endcode %}

**Return Value:**

The Extended Command response output in Hex string format of device raw response for this command.

<table data-header-hidden><thead><tr><th valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Parameter</td><td valign="top">Description</td></tr><tr><td valign="top">errorCode</td><td valign="top">Error status. 0 is Success. Non-Zero is an error.</td></tr><tr><td valign="top">errorMessage</td><td valign="top">Description of the errorCode.</td></tr><tr><td valign="top">opType</td><td valign="top"><p>The type of operation. For this command the value is:</p><p>SEND_EXTENDED_COMMAND_RESULT</p></td></tr><tr><td valign="top">commandID</td><td valign="top">Command that was sent.</td></tr><tr><td valign="top">commandResult</td><td valign="top">Result of a command sent to the device.</td></tr><tr><td valign="top">passInData</td><td valign="top">Optional data to send to MagneFlex. This data will be passed back to the web app.</td></tr></tbody></table>

**Example**

{% hint style="info" %}
<https://192.168.10.100/magneflexdemo/cardpostback.aspx?errorCode=0\\&err> orMessage=OK\&opType=SEND\_EXTENDED\_COMMAND\_RESULT\&commandID=0306\&comman dResult=000001A801A6FA8201A2DFDF2101105F2A0208405F360102DFDF5B010CDFDF 5C0102DFDF75010CDFDF76010CDFDF6E010C9F150230309F1607303030303030309F1A

0208409F1C0831313232333334349F33032028C89F3501219F4005720000B0019F4E07

30303030303030DFDF0109A000000004F8001000DFDF025E9ADFDF289F025A899F109F

159F169F4E828E5F245F259F069F079F0D9F0E9F0F9F269F279F369C9F339F349F379F

399F40959B9F5BDFDF009F1E9F1A5F2A9F019F218ADF8120DF8121DF81225F20505F34

849F039F099F1E9F359F419F53DFDF05299A829F369F1E9F109F5B9F339F35959F015F

245A5F348A9F159F169F399F1A9F1C579F025F2A9F219CDFDF06028A91DFDF14040000

7530DFDF150400000001DFDF160400000080DFDF17599ADFDF289F029F035A899F109F

159F169F4E828E5F245F259F069F079F0D9F0E9F0F9F269F279C9F339F349F359F369F

379F399F409F419F53959B9F5BDFDF009F1E9F1A5F2A9F018ADF8120DF8121DF81225F

205F349F0984DFDF20024328DFDF260E4D414754454B2044454641554C549F3C020998

9F3D0102DFDF4704755EFA9B& passInData=
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.magtek.com/hardware/card-readers/mms-dyna-devices/dynaflex-ii-go/documents/user-manuals/magneflex-browser-developer-tool-programmers-reference-web-api/magneflex-browser-web-api-resources/requestsendextendedcommand.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
