> ## Documentation Index
> Fetch the complete documentation index at: https://docs.alumio.com/llms.txt
> Use this file to discover all available pages before exploring further.

# String: Contains only numbers

> Checks that a string contains only numbers.

export const FormField = ({property, label, required = false, diType, uiPatterns, children}) => {
  const patterns = Array.isArray(uiPatterns) ? uiPatterns : uiPatterns ? [uiPatterns] : [];
  return <div style={{
    margin: '1.5rem 0'
  }}>
      <div style={{
    display: 'flex',
    alignItems: 'baseline',
    flexWrap: 'wrap',
    gap: '0.5rem',
    marginBottom: '0.25rem'
  }}>
        <strong>{label}</strong>
        <span style={{
    fontSize: '0.7rem',
    fontWeight: 600,
    textTransform: 'uppercase',
    letterSpacing: '0.04em',
    color: required ? '#6241f5' : '#6b7280'
  }}>
          {required ? 'Required' : 'Optional'}
        </span>
      </div>

      <div>{children}</div>

      {diType || patterns.length > 0 ? <p style={{
    fontSize: '0.85rem',
    color: '#6b7280',
    marginBottom: 0
  }}>
          {diType ? <>
              See the <a href={`/references/${diType}`}>{diType}</a> reference.{' '}
            </> : null}
          {patterns.length > 0 ? <>
              Accepts a <a href={`/documentation/placeholders-and-patterns/patterns#${patterns[0]}`}>pattern</a>.
            </> : null}
        </p> : null}
    </div>;
};

Checks that a string contains only numbers. A value passes when every character is a digit from 0 to 9, with nothing else in between. Use this to confirm that a value is a plain run of digits before you treat it as one, for example a postal code, an article number, or a barcode. A decimal point, a minus sign, a space, or any letter makes the value fail, and an empty value does not match because it has no digits at all.

This documentation describes: [Schema](/schemas/condition/string-numbers)

## Fields

This condition has no settings to configure. It always checks the value it is given and passes when every character is a digit.

## Sample data

The condition checks each value and answers yes or no:

| Example value | Matches?                         |
| ------------- | -------------------------------- |
| `100245`      | Yes                              |
| `12.50`       | No (contains a decimal point)    |
| `SKU-100`     | No (contains letters and a dash) |

```json Configuration theme={null}
{
  "prototype": "string-numbers",
  "parameters": {}
}
```
