Skip to main content

Searching - QA issues

This page explains how to query segments by QA issues with the search API.

Introduction

To get started, simply add a qa node in the query’s languages node:

CODE
{ 
	"query": {
		"languages": [
    		{ 
              "locs": ["en"],
              "qa": { }               
              ...

An empty node like the above will filter segments that have 1 or more issues in the language.

Filters

The qa node has these options:

qa

When empty then the default filter applies: It will return all segments/texts that have 1 or more active issues. Dismissed issues (like false positives) are not considered active.

CODE
"languages": [
  {
    "qa": { }
    ...

Optional, object

qa.dismissed

Optional boolean.

  • null or missing: no filter

  • false: Search for segments that have at least one active issue in the language (i.e. that is not dismissed)

  • true: Search for segments that have at least one dismissed issue in the language.

Example

CODE
"languages": [
  {
    "qa": { 
      "dismissed": false
    }
    ...

Optional, bool?

qa.severity

Optional list of severity levels to filter.

  • null or missing or []: no filter

  • 0: Language must have at least one issue of severity “Information”

  • 1: Language must have at least one issue of severity “Warning”

  • 2: Language must have at least one issue of severity “Error”

Example

CODE
"languages": [
  {
    "qa": { 
      "severity": [2]
    }
    ...

Optional, int[]?

qa.rules

Optional list of QA rule IDs to filter.

  • null or missing or []: no filter

  • 0: An issue not produced by a QA process

  • 1 .. 1000: Reserved for QA rules built into Wordbee Translator

  • >1000: Any numbers used by an API integrator. See e.g. resources/qa/issues/update (post) which allows to freely set rule IDs.

Example

CODE
"languages": [
  {
    "qa": { 
      "rules": [0, 10, 22]
    }
    ...

Optional, int[]?

Search results

The search results include on text level (node txt) the QA issue details in child node qa:

CODE
...
"txt": {
	"val": "Hello world how are you",
	"st": 0,
	...
	"qa": {
		"dt": "0001-01-01T00:00:00Z",
		"active": false,
		"issues": [
			{
				"s": 2,
				"d": "Grammatical error",
				"r": 10,
				"c": "For your info"
			},
			{
				"s": 1,
				"d": "The translation contains double spaces which are not present in the source text",
				"r": 20
			}
		]
	}                          

If there a no issues at all then qa will be null:

CODE
...
"txt": {
	"val": "Hello world how are you",
	"st": 0,
	...
	"qa": null                         

The properties of qa are:

s

Severity: 0 = Information, 1 = Warning, 2 = error

int

d

Description of issue.

string

r

QA rule ID. See above for the different numerical values.

int

x

Issue dismissed yes/no. If property is missing then consider dismissed being false.

int, Optional

c

Optional comments. If there are no comments then this property will not be output.

string, Optional

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.