# Custom Integration

This guide will walk you through the process of creating a custom integration. Custom Integrations provide you with an alternative in place of any application in your SaaS environment that is, at that point in time, yet to be supported as a SaaS application integration. Follow each step carefully to ensure a successful integration.

Step 1: Display Details

* Select Logo -\
  You have two options to select a logo:
  * Choose Avatar Color

    Select a color for your integration avatar
  * Upload Avatar Image

    Upload a custom image (maximum size: 5KB)
* Enter Integration Details - \
  Provide the following information:
  * Integration Name

    The name of the SaaS service to which the data belongs
  * Display Name

    An alias you can give to the integration

Step 2: Data Source Details

* Upload Data File - \
  Requirements for the data file:
  * File Size

    Maximum file size: 50MB
  * Supported Formats

    CSV and JSON files are supported
  * Template Files

    Download template files to check the expected data format

    CSVJSON

Step 3: Data Validation

* Monitor Data Validation: You can monitor the data validation results to ensure your data is synced correctly and identify any issues.
  * Fix Validation Issues

    If validation fails, you'll need to correct the data format and try again.
  * Complete Integration

    Once validation is successful, you can complete the integration process.

### Data Format Guide

This guide provides detailed information about the required data format for your integration. Please ensure your data follows these specifications exactly.

**Required Fields**

The following field is mandatory and must be included in your data:

* emailId

  User's email address (must be a valid email format)

**Optional Fields**

The following fields are optional and can be included if available:

* firstName

  User's first name (string)
* lastName

  User's last name (string)
* role

  User's role (must be one of:)

  SUPER ADMIN, ADMIN, USER
* createdOn

  Date of creation (format: DDMMYYYY, e.g., 01012024)
* userStatus

  User's status (must be one of:)

  ACTIVE, DISABLED, DELETED
* accountType

  Account type (must be one of:)

  USER, SERVICE
* department

  User's department (string)
* mfaEnrolmentStatus

  MFA enrollment status (true/false)
* accountPaymentStatus

  Payment status (must be one of:)

  PAID, UNPAID, NA

**Data Format Examples**

Here are examples of valid data entries:

JSON Format

```
{
  "firstName": "John",
  "lastName": "Doe",
  "emailId": "john.doe@example.com",
  "department": "Engineering",
  "role": "ADMIN",
  "createdOn": "01012024",
  "mfaEnrolmentStatus": true,
  "userStatus": "ACTIVE",
  "accountPaymentStatus": "PAID",
  "accountType": "USER"
  }
```

CSV Format

```
firstName,lastName,emailId, department, role,createdOn,mfaEnrolmentStatus,userStatus,accountPaymentStatus,accountType
  John, Doe,john.doe@example.com, Engineering, ADMIN,01012024,true,ACTIVE,PAID,USER
```

**Important Notes**

* Data Validation

  All required fields must be present and valid for successful integration
* Date Format

  The createdOn field must follow the DDMMYYYY format (e.g., 01012024 for January 1, 2024)
* Enum Values

  Fields with enum values (role, userStatus, accountPaymentStatus, accountType) must use exact values as specified

NOTE: Providing the latest data and performing a resync would lead to correct evaluation results.


---

# 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://support.perimeters.io/perimeters-documentation/connecting-perimeters/integrations-for-security-insights/saas-applications/custom-integration.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.
