PUT
/
apps
/
{appId}
/
extensions
/
data-masking
/
v1
/
settings
Data masking Store or update settings
curl --request PUT \
  --url https://apimgmt.cometchat.io/apps/{appId}/extensions/data-masking/v1/settings \
  --header 'Content-Type: application/json' \
  --header 'key: <key>' \
  --header 'secret: <secret>' \
  --data '{
  "settings": {
    "dropMessage": false,
    "defaultRegexData": [
      {
        "enableFlag": false,
        "id": "1",
        "name": "US Phone numbers",
        "regex": "[2-9]\\\\d{2}-\\\\d{3}-\\\\d{4}"
      },
      {
        "enableFlag": false,
        "id": "2",
        "name": "Emails",
        "regex": "\\\\w+([.-]?\\\\w+)*@\\\\w+([.-]?\\\\w+)*(\\\\.\\\\w{2,10})+"
      },
      {
        "enableFlag": false,
        "id": "3",
        "name": "SSN",
        "regex": "\\\\d{3}-\\\\d{2}-\\\\d{4}"
      }
    ],
    "customregexData": [
      {
        "name": "one",
        "regex": "one",
        "id": "1983958"
      }
    ],
    "deleteCustomRegexData": [
      "9393903"
    ]
  }
}'
{
  "data": {
    "statusCode": 200,
    "success": true,
    "responseTime": 3.061743974685669,
    "body": {
      "data": {
        "success": true
      }
    }
  }
}

Headers

key
string
required

Authorization Key

secret
string
required

Authorization Secret

Path Parameters

appId
string
required

AppID in which the extension has to be enabled/disabled

Body

application/json

Response

200 - application/json

Update Data Masking Settings

The response is of type object.