Use the iscc function to determine whether a given string is a valid credit card number. This function checks the string against known credit card number patterns and applies a checksum verification (typically the Luhn algorithm) to validate the structure and integrity of the input. You can use iscc when analyzing logs that may contain sensitive data to detect accidental leakage of credit card information. It is also useful when filtering or sanitizing input data, monitoring suspicious behavior, or validating form submissions in telemetry data.

For users of other query languages

If you come from other query languages, this section explains how to adjust your existing queries to achieve the same results in APL.

Usage

Syntax

iscc(value)

Parameters

NameTypeDescription
valuestringThe string to evaluate for validity.

Returns

A bool value:
  • true if the input string is a valid credit card number.
  • false otherwise.

Example

Query
['sample-http-logs']
| extend has_credit_card = iscc('4111111111111111')
| project _time, has_credit_card
Run in Playground Output
_timehas_credit_card
2025-07-10T10:42:00true
  • isimei: Checks whether a value is a valid International Mobile Equipment Identity (IMEI) number.
  • isreal: Checks whether a value is a real number.
  • isstring: Checks whether a value is a string. Use this for scalar string validation.
  • isutf8: Checks whether a value is a valid UTF-8 encoded sequence.