post/patterns

Create Pattern

Request body

Request example
{
  "entity_type": "<Entity Type>",
  "label": "<Label>",
  "description": "",
  "unit": "construction",
  "patterns": [
    "string"
  ],
  "context": [
    "string"
  ],
  "score": 0.8
}

Responses

201Successful Response
Example · 201
{
  "id": "<Id>",
  "entity_type": "<Entity Type>",
  "label": "<Label>",
  "description": "",
  "unit": "<Unit>",
  "patterns": [
    "string"
  ],
  "context": [
    "string"
  ],
  "score": 0,
  "builtin": false,
  "created_at": "string"
}
422Validation Error
Example · 422
{
  "detail": [
    {
      "loc": [
        null
      ],
      "msg": "<Message>",
      "type": "<Error Type>"
    }
  ]
}

Code samples

Generated from the live OpenAPI spec. Replace $SAVITAR_API_KEY with a key from your dashboard.

curl -X POST "https://redact-standalone-service-5j2g6sw72a-el.a.run.app/patterns" \
  -H "Authorization: Bearer $SAVITAR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "entity_type": "<Entity Type>",
  "label": "<Label>",
  "description": "",
  "unit": "construction",
  "patterns": [
    "string"
  ],
  "context": [
    "string"
  ],
  "score": 0.8
}'