Run a labeling/filtering pipeline

The API endpoints described here are defined and configured in Data Pipelines page.

This API has the following variants:

POST /v1/runpipeline/{name}/{entity}?context
Content-Type: application/json | text/xml
JSON or XML payload

Process the input document using the pipeline named name. The input document is an instance of the business entity entity. Since the type of the document is known, JSON/XML validation can be done on the document. This API accepts an optional context as query parameters. The output for this API is the JSON or XML document processed by the named pipeline.

POST /v1/runpipeline/{name}?context
Content-Type: application/json | text/xml
JSON or XML payload

Process the input document using the pipeline named name. The type of input document is unknown, thus JSON or XML validation cannot be performed on it. This API accepts an optional context as query parameters. The output for this API is the JSON or XML document processed by the named pipeline.

POST /v1/runpipeline/{name}/{entity}
Content-Type: multipart/mixed; boundary=123abcd
--123abcd
Content-Type: application/json
Context (JSON)
--123abcd
Content-Type: application/json | text/xml
JSON or XML payload
--123abcd
Content-Type: application/json | text/xml
JSON or XML payload

Process the input documents using the given pipeline name. The documents are instances of the business entity entity. Since the type of the document is known, JSON/XML validation can be performed on the document. The context JSON document is given in the first part of the multipart body. The output is a multi-part stream containing filtered payloads, in the same order they were submitted.

The Context

The context describes the current real-world situation so that data subject consent can be evaluated. The filtering APIs will record the consent as part of the audit trail. Data subject reports will show what type of data was filtered under what context, and what privacy labels were allowed or denied. Read more about context.

Context can be specified as a JSON document for multi-part requests. For single JSON or XML requests, context can be specified using query parameters as follows:

string.context.fieldName=stringValue

This query parameter defines the context.fieldName field as a string with the value of stringValue.

boolean.context.fieldName=true

This query parameter defines the context.fieldName field as a boolean field with the value of true.

number.context.fieldName=1

This query parameter defines the context.fieldName field as a number with the value of 1.

The following example illustrates a set of query parameters, and its corresponding JSON equivalent:

string.context.recipients[0]=rcpt1& 1
 string.context.recipients[1]=rcpt2& 
 number.context.count=1& 2
 boolean.context.flag=false 3

"context": {
  "recipients": [ "rcpt1", "rcpt2" ], 1
  "count": 1, 2
  "flag": false 3
}