Endpoint /documentprocessing/barcodes/istextvalid

GET https://example.com/documentprocessing/barcodes/istextvalid


Returns the minimum text length that can be encoded.


The following example checks, if a text is valid for a QR code.

# Request:
curl --location --request GET 'https://trial.dsserver.io/documentprocessing/barcodes/istextvalid?barcodeType=qrcode&text=test_*+%C3%91%E1%B9%BC' \
    --header 'Authorization: Bearer fePFHv8OtIyRSCAdOnn7USc9kKdYB2rg'

# Result:
"The text is invalid. For the barcode type QR Code, only ASCII (ISO 8859-1) characters are allowed."


This endpoint supports the OAuth authorization method:


DS Server implements OAuth as the authorization method. Two flows are supported:

  • Authorization Code
  • Client Credentials

In order to use the Client Credentials flow, this method must be explicitly enabled in the admin portal of DS Server.

In both cases, a valid access token returned from the OAuth endpoints must be passed in a Bearer Authorization Header or as a Query Parameter.

Authorization Header

Header Field Description

A Bearer authorization header (also called token authentication) contains the OAuth access token. The authorization method and a space i.e. "Bearer " is then put before your valid access token. For example:

Authorization: Bearer 4796E23054E64BC773CACBCAF24AD179DE9A3

Query Parameter

Query Parameter Description

The access token is passed directly in the endpoint URL as a query string. For example:


Request Parameters

Name Type Value Optional
barcodeType String A string that specifies the barcode type. Possible values are: "QRCode", "Code128", "EAN13", "UPCA", "EAN8", "Interleaved2of5", "Postnet ", "Code39", "AztecCode", "IntelligentMail", "Datamatrix", "PDF417", "MicroPDF", "Codabar", "FourState", "Code11", "Code93", "PLANET", "RoyalMail", "Maxicode". Default value is "PNG". no
text String A string that should be tested for the given barcode type. no

Success Response

Status Description
200 On success, the HTTP status code in the response header is 200 (OK). If text is invalid, information is returned about the invalid text.

Error Response

Status Description
401 A 401 (Unauthorized) is returned, if the user is not authorized.
400 A 400 (Bad Request) is returned, if DS Server is not licensed or the license is invalid.
400 A 400 (Bad Request) is returned, if the barcode type is not valid.