# Setup Accura MICR

### Setting up License

```
  getAccuraSetup = () => {
    //Method for get license info from native OS.
    AccurascanOcr.getMetaData((error, response) => {
      if (error != null) {

      } else {
        console.log(response);
      }
    });
  };
```

**Error:** String

**Success:** JSON String Response = { isValid: boolean, isMICR:boolean }

***

### Setting up Configuration's,Error mssages and Scaning title messages

```
   setUpCustomMessages = () => {
      var config = {
        setMinGlarePercentage: 6,
        setMaxGlarePercentage: 99,
        setBlurPercentage: 60,
      };
  
      var accuraConfigs = {
        CameraScreen_CornerBorder_Enable: true,
        CameraScreen_Border_Width: 15,
        Disable_Card_Name: false,
        enableLogs: 0,
        setCameraFacing: 0,
        isShowLogo: 1,
        CameraScreen_Frame_Color: '#D5323F',
        CameraScreen_Text_Color: '#FFFFFF',
        CameraScreen_Text_Border_Color: '#000000',
        CameraScreen_Color: '#80000000',
        CameraScreen_Back_Button: 1,
        CameraScreen_Change_Button: 1,
        ACCURA_ERROR_CODE_MOTION: 'Keep Document Steady',
        ACCURA_ERROR_CODE_DOCUMENT_IN_FRAME: 'Keep document in frame',
        ACCURA_ERROR_CODE_BRING_DOCUMENT_IN_FRAME: 'Bring card near to frame',
        ACCURA_ERROR_CODE_PROCESSING: 'Processing...',
        ACCURA_ERROR_CODE_BLUR_DOCUMENT: 'Blur detect in document',
        ACCURA_ERROR_CODE_GLARE_DOCUMENT: 'Glare detect in document',
        ACCURA_ERROR_CODE_DARK_DOCUMENT: 'Low lighting detected',
        ACCURA_ERROR_CODE_MOVE_CLOSER: "Move closer to document",
        ACCURA_ERROR_CODE_MOVE_AWAY:"Move away from document",
        ACCURA_ERROR_CODE_KEEP_MICR_IN_FRAME: "Keep MICR in frame",
      };
  
      var accuraTitleMsg = {
        SCAN_TITLE_MICR: 'Scan Cheque',

      };
  
      //Method for setup config into native OS.
      AccurascanOcr.setupAccuraConfig(
        [config, accuraConfigs, accuraTitleMsg],
        (error, response) => {
          if (error != null) {
            console.log('Failure!', error);
          } else {
            console.log('Message:- ', response);
          }
        }
      );
    };    
```

***

### Method for scan MICR documents.

```
onPressMICR = () => {
   let passArgs = [ micrSelected]; //e13b or cmc7
   //Method for start MICR scaning from native OS.
   AccurascanOcr.startMRZ(passArgs, (error, response) => {
     if (error != null) {
       console.log('Failure!', error);
        showAlert('Failure!', error);
     } else {
       console.log('Success!', response);
     }
   });
};
```

**Success:** JSON Response { front\_data: JSONObjects?, front\_img: URI? }

**Error:** String

***


---

# 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://docs.accurascan.com/solutions/micr-cheque-scanner/react-native/setup-accura-micr.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.
