# AsyncExtractDocument

This method is a similar method to ExtractDocument but instead of returning a big JSON/XML document after a while, it instantly returns a UUID for the extracted document which allows high quantities of documents to be extracted at the same time. These extracted files then can be retrieved by using the GetDocumentByUUID method.

## AsyncExtractDocument

<mark style="color:green;">`POST`</mark> `https://testapi.onvision.ai/wsservice.asmx`

Use this to get the UUID of the extracted document as a JSON result.

#### Path Parameters

| Name      | Type   | Description               |
| --------- | ------ | ------------------------- |
| TOKEN     | string | Token                     |
| FileName  | string | File name                 |
| byteArray | string | Byte array (base64Binary) |

{% tabs %}
{% tab title="200 Response when the credentials are valid." %}

```javascript
{
	"Envelope": {
		"Success": "1",
		"Message": "",
		"Info": {
			"Version": "1.0.0",
			"Run_Date": "20211008113007",
			"Executed_ms": "26.003"
		},
		"Result": {
			"document": {
				"system_info": {
					"version": "1.0",
					"UUID": "9210db16-66d2-4866-ba60-a5e03a8ecf2a",
					"FileName": "4944ec73-3d59-4597-8a03-1392ccc9f214",
					"result": ""
				},
				"data": "9210db16-66d2-4866-ba60-a5e03a8ecf2a"
			}
		}
	}
}
```

{% endtab %}
{% endtabs %}

## AsyncExtractDocument

<mark style="color:green;">`POST`</mark> `https://testapi.onvision.ai/wsserviceNet.asmx`

Use this to get the UUID of the extracted document as a XML result.

#### Path Parameters

| Name      | Type   | Description               |
| --------- | ------ | ------------------------- |
| TOKEN     | string | Token                     |
| FileName  | string | File name                 |
| byteArray | string | Byte array (base64Binary) |

{% tabs %}
{% tab title="200 Response when the credentials are valid." %}

```markup
<Envelope>
	<Success>1</Success>
	<Message></Message>
	<Info>
		<Version>1.0.0</Version>
		<Run_Date>20211008113007</Run_Date>
		<Executed_ms>26.003</Executed_ms>
	</Info>
	<Result>
		<document>
			<system_info>
				<version>1.0</version>
				<UUID>9210db16-66d2-4866-ba60-a5e03a8ecf2a</UUID>
				<FileName>4944ec73-3d59-4597-8a03-1392ccc9f214</FileName>
				<result></result>
			</system_info>
			<data>9210db16-66d2-4866-ba60-a5e03a8ecf2a</data>
		</document>
	</Result>
</Envelope>
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: 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://docs.onvision.ai/api-book/api/asyncextractdocument.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.
