Async APIsMask Async with Policy

Mask Async with Policy

Submit a masked data request with a named policy, receive a tracking ID and status, then poll for the completed result.

{
  "policy_name": "customer-support-policy",
  "mask": [
    {
      "value": "https://platform.openai.com/playground/chat?models=gpt-4o",
      "format": "URL",
      "token_name": "Text Token"
    },
    {
      "value": "(408)- 426 - 9989",
      "format": "Phone Number",
      "token_name": "Numeric Token"
    }
  ]
}
{
  "data": [
    {
      "tracking_id": "bab9dad6-bd3b-4b73-93a0-7ba56aaa4d6229102026064556",
      "status": "PENDING"
    }
  ],
  "success": true,
  "error": {
    "message": ""
  }
}

Endpoint

MethodEndpoint
PUT{baseurl}/mask/async

The policy must already exist in the namespace before you make this request. Create a policy before continuing.

policy_name selects the policy to apply.

Request body

body
policy_namestring
Required

Name of the policy to apply.

body
maskarray
Required

Values to mask using the selected policy.

After submission

The response returns a tracking ID and status. Poll the Async Status endpoint with the returned tracking ID to retrieve the completed result.