{
  "openapi": {
    "info": {
      "title": "sanitize",
      "description": "Clean file of potentially malicious content",
      "version": "2",
      "x-pangea-ui-schema": {}
    },
    "servers": [
      {
        "url": "https://sanitize.aws.us.pangea.cloud",
        "description": "Pangea regional service cluster"
      }
    ],
    "paths": {
      "/v1/sanitize": {
        "post": {
          "operationId": "sanitize_post_v1_sanitize",
          "summary": "Sanitize Files",
          "description": "Apply file sanitization actions according to specified rules.\n\n&nbsp;\n\nRefer to the [Transfer Methods](/docs/api/transfer-methods) document for details on using `transfer_method` and `share_output` parameters for providing the input and receiving the sanitized output.\n\n&nbsp;",
          "x-pangea-ui-schema": {
            "hideContentTypePicker": true
          },
          "requestBody": {
            "content": {
              "multipart/form-data": {
                "schema": {
                  "$id": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/paths/~1v1~1sanitize/requestBody/content/multipart~1form-data/schema",
                  "$schema": "https://json-schema.org/draft/2020-12/schema",
                  "$defs": {},
                  "required": ["request", "upload"],
                  "type": "object",
                  "properties": {
                    "request": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": ["transfer_method"],
                      "properties": {
                        "transfer_method": {
                          "description": "The transfer method used to upload the file data.",
                          "type": "string",
                          "enum": [
                            "multipart",
                            "source-url",
                            "put-url",
                            "post-url",
                            "share-id"
                          ],
                          "x-pangea-ui-schema": {
                            "default": "multipart"
                          }
                        },
                        "source_url": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-source-url"
                        },
                        "share_id": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-share-id"
                        },
                        "file": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/api-sanitize-file-level-config"
                        },
                        "content": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/api-sanitize-content-level-config"
                        },
                        "share_output": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/api-sanitize-share-output-config"
                        },
                        "size": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-size"
                        },
                        "crc32c": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-crc32c"
                        },
                        "sha256": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-sha256"
                        },
                        "uploaded_file_name": {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-uploaded-file-name"
                        }
                      },
                      "allOf": [
                        {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-require-source-url"
                        },
                        {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-required-share-id"
                        },
                        {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-required-post-url"
                        },
                        {
                          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-require-put-url"
                        }
                      ]
                    },
                    "upload": {}
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": false,
                  "required": ["transfer_method"],
                  "properties": {
                    "transfer_method": {
                      "description": "The transfer method used to upload the file data.",
                      "type": "string",
                      "enum": [
                        "multipart",
                        "source-url",
                        "put-url",
                        "post-url",
                        "share-id"
                      ],
                      "x-pangea-ui-schema": {
                        "default": "source-url"
                      }
                    },
                    "source_url": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-source-url"
                    },
                    "share_id": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-share-id"
                    },
                    "file": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/api-sanitize-file-level-config"
                    },
                    "content": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/api-sanitize-content-level-config"
                    },
                    "share_output": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/api-sanitize-share-output-config"
                    },
                    "size": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-size"
                    },
                    "crc32c": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-crc32c"
                    },
                    "sha256": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-sha256"
                    },
                    "uploaded_file_name": {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-field-uploaded-file-name"
                    }
                  },
                  "allOf": [
                    {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-require-source-url"
                    },
                    {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-required-share-id"
                    },
                    {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-required-post-url"
                    },
                    {
                      "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-require-put-url"
                    }
                  ],
                  "$id": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/paths/~1v1~1sanitize/requestBody/content/application~1json/schema"
                }
              }
            }
          },
          "responses": {
            "200": {
              "content": {
                "application/json": {
                  "schema": {
                    "$id": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/paths/~1v1~1sanitize/responses/200/content/application~1json/schema",
                    "$schema": "https://json-schema.org/draft/2020-12/schema",
                    "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/pangea-response",
                    "$defs": {},
                    "properties": {
                      "result": {
                        "type": "object",
                        "properties": {
                          "dest_url": {
                            "type": "string",
                            "format": "uri",
                            "description": "A URL where the Sanitized file can be downloaded."
                          },
                          "dest_share_id": {
                            "type": "string",
                            "description": "Pangea Secure Share ID of the Sanitized file."
                          },
                          "data": {
                            "type": "object",
                            "properties": {
                              "defang": {
                                "type": "object",
                                "properties": {
                                  "external_urls_count": {
                                    "type": "integer",
                                    "description": "Number of external links found."
                                  },
                                  "external_domains_count": {
                                    "type": "integer",
                                    "description": "Number of external domains found."
                                  },
                                  "defanged_count": {
                                    "type": "integer",
                                    "description": "Number of items defanged per provided rules and detections."
                                  },
                                  "url_intel_summary": {
                                    "type": "string",
                                    "description": "Processed N URLs: X are malicious, Y are suspicious, Z are unknown."
                                  },
                                  "domain_intel_summary": {
                                    "type": "string",
                                    "description": "Processed N Domains: X are malicious, Y are suspicious, Z are unknown."
                                  }
                                }
                              },
                              "redact": {
                                "type": "object",
                                "properties": {
                                  "redaction_count": {
                                    "type": "integer",
                                    "description": "Number of items redacted"
                                  },
                                  "summary_counts": {
                                    "type": "object",
                                    "patternProperties": {
                                      ".*": {
                                        "type": "integer",
                                        "example": 0
                                      }
                                    }
                                  },
                                  "recognizer_results": {
                                    "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/redact-recognizer-results"
                                  }
                                }
                              },
                              "malicious_file": {
                                "type": "boolean",
                                "description": "If the file scanned was malicious"
                              },
                              "cdr": {
                                "type": "object",
                                "properties": {
                                  "file_attachments_removed": {
                                    "type": "integer",
                                    "description": "Number of file attachments removed"
                                  },
                                  "interactive_contents_removed": {
                                    "type": "integer",
                                    "description": "Number of interactive content items removed"
                                  }
                                }
                              }
                            }
                          },
                          "parameters": {
                            "type": "object",
                            "description": "The parameters, which were passed in the request, echoed back",
                            "properties": {}
                          }
                        }
                      }
                    }
                  }
                }
              },
              "description": "No description provided"
            },
            "400": {
              "description": "Validation errors",
              "content": {
                "application/json": {
                  "schema": {
                    "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/pangea-validation-errors"
                  }
                }
              }
            }
          }
        }
      }
    },
    "openapi": "3.1.0",
    "components": {
      "schemas": {
        "pangea-response": {
          "title": "Response Schema",
          "description": "Pangea standard response schema",
          "type": "object",
          "required": ["request_id", "request_time", "response_time", "status"],
          "properties": {
            "request_id": {
              "type": "string",
              "description": "A unique identifier assigned to each request made to the API. It is used to track and identify a specific request and its associated data. The `request_id` can be helpful for troubleshooting, auditing, and tracing the flow of requests within the system. It allows users to reference and retrieve information related to a particular request, such as the response, parameters, and raw data associated with that specific request.\n\n```\n\"request_id\":\"prq_x6fdiizbon6j3bsdvnpmwxsz2aan7fqd\"\n```"
            },
            "request_time": {
              "type": "string",
              "description": "The timestamp indicates the exact moment when a request is made to the API. It represents the date and time at which the request was initiated by the client. The `request_time` is useful for tracking and analyzing the timing of requests, measuring response times, and monitoring performance metrics. It allows users to determine the duration between the request initiation and the corresponding response, aiding in the assessment of API performance and latency.\n\n```\n\"request_time\":\"2022-09-21T17:24:33.105Z\"\n```"
            },
            "response_time": {
              "type": "string",
              "description": "Duration it takes for the API to process a request and generate a response. It represents the elapsed time from when the request is received by the API to when the corresponding response is returned to the client.\n\n```\n\"response_time\":\"2022-09-21T17:24:34.007Z\"\n```"
            },
            "status": {
              "type": "string",
              "description": "It represents the status or outcome of the API request made for IP information. It indicates the current state or condition of the request and provides information on the success or failure of the request.\n\n```\n\"status\":\"success\"\n```"
            },
            "summary": {
              "type": "string",
              "description": "Provides a concise and brief overview of the purpose or primary objective of the API endpoint. It serves as a high-level summary or description of the functionality or feature offered by the endpoint."
            },
            "result": {
              "type": "object"
            }
          },
          "examples": [
            {
              "request_id": "prq_x6fdiizbon6j3bsdvnpmwxsz2aan7fqd",
              "request_time": "2022-09-21T17:24:33.105Z",
              "response_time": "2022-09-21T17:24:34.007Z",
              "status": "success"
            }
          ],
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/pangea-response"
        },
        "pangea-validation-errors": {
          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/pangea-response",
          "required": ["result"],
          "properties": {
            "result": {
              "type": "object",
              "required": ["errors"],
              "properties": {
                "errors": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "type": "object",
                    "required": ["code", "detail", "source"],
                    "properties": {
                      "code": {
                        "type": "string",
                        "enum": [
                          "FieldRequired",
                          "InvalidString",
                          "InvalidNumber",
                          "InvalidInteger",
                          "InvalidObject",
                          "InvalidArray",
                          "InvalidNull",
                          "InvalidBool",
                          "BadFormat",
                          "BadFormatPangeaDuration",
                          "BadFormatDateTime",
                          "BadFormatTime",
                          "BadFormatDate",
                          "BadFormatEmail",
                          "BadFormatHostname",
                          "BadFormatIPv4",
                          "BadFormatIPv6",
                          "BadFormatIPAddress",
                          "BadFormatUUID",
                          "BadFormatURI",
                          "BadFormatURIReference",
                          "BadFormatIRI",
                          "BadFormatIRIReference",
                          "BadFormatJSONPointer",
                          "BadFormatRelativeJSONPointer",
                          "BadFormatRegex",
                          "BadFormatJSONPath",
                          "BadFormatBase64",
                          "DoesNotMatchPattern",
                          "DoesNotMatchPatternProperties",
                          "NotEnumMember",
                          "AboveMaxLength",
                          "BelowMinLength",
                          "AboveMaxItems",
                          "BelowMinItems",
                          "NotMultipleOf",
                          "NotWithinRange",
                          "UnexpectedProperty",
                          "InvalidPropertyName",
                          "AboveMaxProperties",
                          "BelowMinProperties",
                          "NotContains",
                          "ContainsTooMany",
                          "ContainsTooFew",
                          "ItemNotUnique",
                          "UnexpectedAdditionalItem",
                          "InvalidConst",
                          "IsDependentOn",
                          "IsTooBig",
                          "IsTooSmall",
                          "ShouldNotBeValid",
                          "NoUnevaluatedItems",
                          "NoUnevaluatedProperties",
                          "DoesNotExist",
                          "IsReadOnly",
                          "CannotAddToDefault",
                          "MustProvideOne",
                          "MutuallyExclusive",
                          "BadState",
                          "InaccessibleURI",
                          "ProviderDisabled",
                          "ConfigProjectMismatch",
                          "ConfigServiceMismatch",
                          "ConfigNotExist"
                        ]
                      },
                      "detail": {
                        "type": "string",
                        "description": "Human readable description of the error"
                      },
                      "source": {
                        "type": "string",
                        "description": "Path to the data source of the error",
                        "format": "json-pointer"
                      },
                      "path": {
                        "type": "string",
                        "description": "The Schema path where the error occurred",
                        "format": "json-pointer"
                      }
                    }
                  }
                }
              }
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/pangea-validation-errors"
        },
        "sanitize-cdr-config": {
          "type": "object",
          "required": [],
          "properties": {
            "remove_attachments": {
              "type": "boolean",
              "default": true,
              "examples": [false],
              "description": "Remove file attachments (PDF only)."
            },
            "remove_interactive": {
              "type": "boolean",
              "default": true,
              "examples": [false],
              "description": "Remove interactive content (PDF only)."
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-cdr-config"
        },
        "sanitize-scan-config": {
          "type": "object",
          "required": [],
          "properties": {
            "scan_service_config_id": {
              "description": "A File Scan service config that will be used to perform scanning.",
              "type": "string"
            },
            "scan_provider": {
              "description": "Provider to use for Scan",
              "type": "string"
            },
            "block_unable_to_scan": {
              "type": "boolean",
              "default": false,
              "examples": [true],
              "description": "Block files that can not be Scanned (unsupported Scan type, password-protected, encrypted, etc)."
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-scan-config"
        },
        "sanitize-defang-config": {
          "type": "object",
          "required": [],
          "properties": {
            "enabled": {
              "type": "boolean",
              "default": true,
              "examples": [false],
              "description": "Defang links."
            },
            "url_intel": {
              "type": "boolean",
              "default": false,
              "examples": [false],
              "description": "Use URL Threat Intel lookups."
            },
            "domain_intel": {
              "type": "boolean",
              "default": false,
              "examples": [false],
              "description": "Use Domain Threat Intel lookups."
            },
            "risk_threshold": {
              "type": "integer",
              "description": "Defang risk threshold."
            },
            "url_intel_config_id": {
              "description": "A URL Intel config that will be used to perform URL lookups.",
              "type": "string"
            },
            "domain_intel_config_id": {
              "description": "A Domain Intel config that will be used to perform Domain lookups.",
              "type": "string"
            },
            "url_intel_provider": {
              "description": "Provider to use for URL Intel",
              "type": "string"
            },
            "domain_intel_provider": {
              "description": "Provider to use for Domain Intel",
              "type": "string"
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-defang-config"
        },
        "sanitize-redact-config": {
          "type": "object",
          "required": [],
          "properties": {
            "enabled": {
              "type": "boolean",
              "default": false,
              "examples": [true],
              "description": "Redact sensitive content."
            },
            "redact_service_config_id": {
              "description": "A redact service config that will be used to redact sensitive content.",
              "type": "string"
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-redact-config"
        },
        "sanitize-sos-config": {
          "type": "object",
          "required": [],
          "properties": {
            "enabled": {
              "type": "boolean",
              "default": false,
              "examples": [true],
              "description": "Integrate with Secure Share."
            },
            "share_service_config_id": {
              "description": "A Secure Share service config that will be used to store sanitized files.",
              "type": "string"
            },
            "retention_days": {
              "type": "integer"
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-sos-config"
        },
        "sanitize-service-config": {
          "type": "object",
          "required": ["name"],
          "properties": {
            "id": {
              "type": "string",
              "description": "The config ID"
            },
            "version": {
              "type": "integer",
              "default": 1,
              "readOnly": true
            },
            "created_at": {
              "type": "string",
              "description": "The DB timestamp when this config was created. Ignored when submitted.",
              "format": "date-time"
            },
            "updated_at": {
              "type": "string",
              "description": "The DB timestamp when this config was last updated at",
              "format": "date-time"
            },
            "name": {
              "description": "configuration name",
              "type": "string"
            },
            "cdr": {
              "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-cdr-config"
            },
            "scan": {
              "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-scan-config"
            },
            "defang": {
              "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-defang-config"
            },
            "redact": {
              "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-redact-config"
            },
            "sos": {
              "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-sos-config"
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-service-config"
        },
        "sanitize-service-config-result": {
          "required": ["id", "version", "name", "updated_at"],
          "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/sanitize-service-config",
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-service-config-result"
        },
        "api-sanitize-file-level-config": {
          "type": "object",
          "properties": {
            "scan_provider": {
              "description": "Provider to use for File Scan",
              "type": "string",
              "default": "crowdstrike",
              "enum": ["crowdstrike", "reversinglabs"],
              "examples": ["crowdstrike"]
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/api-sanitize-file-level-config"
        },
        "api-sanitize-content-level-config": {
          "type": "object",
          "properties": {
            "url_intel": {
              "type": "boolean",
              "default": true,
              "examples": [false],
              "description": "Perform URL Intel lookup"
            },
            "url_intel_provider": {
              "description": "Provider to use for URL Intel",
              "type": "string",
              "default": "crowdstrike",
              "enum": ["crowdstrike"],
              "examples": ["crowdstrike"]
            },
            "domain_intel": {
              "type": "boolean",
              "default": true,
              "examples": [false],
              "description": "Perform Domain Intel lookup"
            },
            "domain_intel_provider": {
              "description": "Provider to use for Domain Intel lookup",
              "type": "string",
              "default": "crowdstrike",
              "enum": ["crowdstrike", "domaintools"],
              "examples": ["crowdstrike"]
            },
            "defang": {
              "type": "boolean",
              "default": true,
              "examples": [false],
              "description": "Defang external links."
            },
            "defang_threshold": {
              "type": "integer",
              "default": 30,
              "description": "Defang risk threshold."
            },
            "redact": {
              "type": "boolean",
              "default": false,
              "examples": [true],
              "description": "Redact sensitive content."
            },
            "redact_detect_only": {
              "type": "boolean",
              "description": "If redact is enabled, avoids redacting the file and instead returns the PII analysis engine results. Only works if redact is enabled"
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/api-sanitize-content-level-config"
        },
        "api-sanitize-share-output-config": {
          "type": "object",
          "properties": {
            "enabled": {
              "type": "boolean",
              "default": false,
              "examples": [true],
              "description": "Store Sanitized files to Pangea Secure Share.\n\nIf not enabled, a presigned URL will be returned in 'result.dest_url'."
            },
            "output_folder": {
              "description": "Store Sanitized files to this Secure Share folder (will be auto-created if not exists)",
              "type": "string",
              "default": ""
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/api-sanitize-share-output-config"
        },
        "sanitize-field-crc32c": {
          "description": "The CRC32C hash of the file data, which will be verified by the server if provided.",
          "type": "string",
          "contentEncoding": "base64",
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-field-crc32c"
        },
        "sanitize-field-size": {
          "type": "number",
          "description": "The size (in bytes) of the file. If the upload doesn't match, the call will fail.",
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-field-size"
        },
        "sanitize-field-sha256": {
          "type": "string",
          "pattern": "^[0123456789abcdef]{64}$",
          "description": "The hexadecimal-encoded SHA256 hash of the file data, which will be verified by the server if provided.",
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-field-sha256"
        },
        "sanitize-field-uploaded-file-name": {
          "type": "string",
          "description": "Name of the user-uploaded file, required for transfer-method 'put-url' and 'post-url'.",
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-field-uploaded-file-name"
        },
        "sanitize-field-share-id": {
          "type": "string",
          "description": "A Pangea Secure Share ID where the file to be Sanitized is stored.",
          "minLength": 36,
          "examples": ["pos_3djfmzg2db4c6donarecbyv5begtj2bm"],
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-field-share-id"
        },
        "sanitize-field-source-url": {
          "type": "string",
          "format": "uri",
          "description": "A URL where the file to be Sanitized can be downloaded.",
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-field-source-url"
        },
        "sanitize-require-source-url": {
          "if": {
            "properties": {
              "transfer_method": {
                "const": "source-url"
              }
            },
            "required": ["transfer_method"]
          },
          "then": {
            "required": ["source_url"]
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-require-source-url"
        },
        "sanitize-required-share-id": {
          "if": {
            "properties": {
              "transfer_method": {
                "const": "share-id"
              }
            },
            "required": ["transfer_method"]
          },
          "then": {
            "required": ["share_id"]
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-required-share-id"
        },
        "sanitize-required-post-url": {
          "if": {
            "properties": {
              "transfer_method": {
                "const": "post-url"
              }
            },
            "required": ["transfer_method"]
          },
          "then": {
            "required": ["sha256", "crc32c", "size", "uploaded_file_name"]
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-required-post-url"
        },
        "sanitize-require-put-url": {
          "if": {
            "properties": {
              "transfer_method": {
                "const": "put-url"
              }
            },
            "required": ["transfer_method"]
          },
          "then": {
            "required": ["uploaded_file_name"]
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/sanitize-require-put-url"
        },
        "redact-recognizer-results": {
          "description": "The scoring result of a set of rules",
          "type": "array",
          "items": {
            "type": "object",
            "required": [
              "field_type",
              "score",
              "text",
              "start",
              "end",
              "redacted"
            ],
            "properties": {
              "field_type": {
                "type": "string",
                "description": "The entity name"
              },
              "score": {
                "type": "number",
                "description": "The certainty score that the entity matches this specific snippet"
              },
              "text": {
                "type": "string",
                "description": "The text snippet that matched"
              },
              "start": {
                "type": "integer",
                "description": "The starting index of a snippet"
              },
              "end": {
                "type": "integer",
                "description": "The ending index of a snippet"
              },
              "redacted": {
                "type": "boolean",
                "description": "Indicates if this rule was used to anonymize a text snippet"
              },
              "data_key": {
                "type": ["string", "null"],
                "description": "If this result relates to a specific structured text field, the key pointing to this text will be provided"
              },
              "context_results": {
                "type": ["object", "null"],
                "description": "Context information If context was applied to score",
                "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/redact-context-score-result"
              },
              "negative_context_results": {
                "type": ["object", "null"],
                "description": "Context information If negative context was applied to score",
                "$ref": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json#/components/schemas/redact-context-score-result"
              }
            }
          },
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/redact-recognizer-results"
        },
        "redact-context-score-result": {
          "required": ["word", "start", "end", "score_augment"],
          "properties": {
            "word": {
              "type": "string"
            }
          },
          "additionalProperties": false,
          "$id": "https://pangea.cloud/docs/openapi/sanitize_openapi.json#/components/schemas/redact-context-score-result"
        }
      },
      "securitySchemes": {
        "APIToken": {
          "type": "http",
          "bearerFormat": "token",
          "description": "Pangea API Token",
          "scheme": "bearer"
        }
      }
    },
    "jsonSchemaDialect": "https://json-schema.org/draft/2020-12/schema"
  },
  "remoteDocuments": {},
  "url": "https://sanitize.aws.us.pangea.cloud/v1/openapi.json"
}
