dai_status: Check job status

Description Usage Arguments Value Examples

View source: R/send_to_dai.R

Description

Queries the Google Cloud Services (GCS) Document AI v1 API about the status of a previously submitted asynchronous job.

Usage

1
dai_status(response, loc = "eu", token = dai_token(), verbose = FALSE)

Arguments

response

a HTTP response object generated by dai_async()

loc

A two-letter region code; "eu" or "us"

token

An authentication token generated by dai_auth() or another auth function

verbose

Whether to output the full response; boolean

Value

If verbose was set to TRUE, a HTTP response object. If verbose was set to FALSE, a string summarizing the status.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
# Short status message:
response <- dai_async(myfiles)
dai_status(response)

# Full status details:
response <- dai_async(myfiles)
status <- dai_status(response, verbose = TRUE)

## End(Not run)

daiR documentation built on June 11, 2021, 5:16 p.m.