The API requires some text as input, which you can provide in one of the input parameters. The text parameter accepts a block of text:
/1/api/[async|sync]/gettextstatistics/v1?text=Shall I compare thee to a summer's day
You can also provide a file, a Haven OnDemand object store reference, or a URL.
For any input format, the API extracts the text and returns statistical information about the contents, such as the number of terms, and the percentage of different types of character (alphabetic, numeric, punctuation, and so on).