# Validators

{% code lineNumbers="true" %}

```javascript
  Validator.isNumeric(str:string):bool
 
  Validator.isMail(str:string):bool
 
  Validator.isHex(str:string):bool
 
  Validator.isBase64(str:string):bool
 
  Validator.isBase32(str:string):bool
 
  Validator.isMACAddress(str:string):bool
 
  Validator.isOctal(str:string):bool
 
  Validator.isJSON(str:string):bool
 
  Validator.isStrongPassword(str:string):bool
 
  Validator.isAscii(str:string):bool
 
  Validator.isIP(str:string):bool
 
```

{% endcode %}

**Example**\`\`\`javascript

```javascript
if ((await Validator.isNumeric("1234"))==false)
    return {error:1,message:'Its Not A Numeric!'};
else
    return {error:0};
```

```javascript
When the above codes executed  Screen returns 
{error:0}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://smartscenarios.pirichain.com/psce-functions/validators.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
