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

# Individual Module

> The Individual Module provides a streamlined interface to interact with Know Your Customer (KYC) APIs, enabling you to create, update, and verify individuals during your platform’s onboarding process.

## Quick Implementation

```javascript title="Initialize the Module" theme={null}
// Create an instance of the Individual module
const individual = oneSdk.individual();

// Add required user consent
individual.addConsent("general");

```

## Core Methods

<AccordionGroup>
  <Accordion title="Access User Properties">
    Use `individual.access()` to manage core user properties:

    ```javascript theme={null}
    const { setValue, getValue } = individual.access('name');

    // Example: Setting user name properties
    setValue({
        givenName: 'Albert',
        familyName: 'Einstein',
        middleName: 'J',
        displayName: 'Albert Einstein',
    });
    ```

    <Callout icon="thumbtack" color="#1A6CFF" iconType="regular">
      By using setValue() method on individual module, you are adding details on an entity, that will get pre-filled on your eKYC Form module.
    </Callout>

    Available properties:

    | Property      | Description                                                    |
    | ------------- | -------------------------------------------------------------- |
    | `addresses`   | User's addresses. See Address Properties table below           |
    | `dateOfBirth` | User's date of birth                                           |
    | `documents`   | Identity documents                                             |
    | `email`       | Contact email address                                          |
    | `entityId`    | user's entityId (Note: there's no `setValue` on this property) |
    | `name`        | User's name information                                        |
    | `phoneNumber` | Contact phone number                                           |
    | `profile`     | User profile details                                           |

    Address Properties:

    | Property       | Description                                                                                                                                                                                                                                      |
    | -------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
    | `addressType`  | RESIDENTIAL1 for primary address; RESIDENTIAL2 for additional address                                                                                                                                                                            |
    | `buildingName` | Building name                                                                                                                                                                                                                                    |
    | `country`      | User's country in ISO 3166-1 alpha-3 format                                                                                                                                                                                                      |
    | `longForm`     | User's long form address <br />- Only fill this data if you do not have broken down address <br />- Make sure to fill out `data.longForm` along with \`longForm <br />- The address will be broken down by FrankieOne system upon running checks |
    | `postal`       | Postal address                                                                                                                                                                                                                                   |
    | `state`        | User's state                                                                                                                                                                                                                                     |
    | `streetName`   | User's street name                                                                                                                                                                                                                               |
    | `streetNumber` | User's street number                                                                                                                                                                                                                             |
    | `streetType`   | User's street type, for example, \*Road, St., Ave, Circuit, and others                                                                                                                                                                           |
    | `suburb`       | User's suburb                                                                                                                                                                                                                                    |
    | `unitNumber`   | User's unit number                                                                                                                                                                                                                               |
  </Accordion>

  <Accordion title="Consent Management">
    ```javascript theme={null}
    // Add user consent programmatically
    individual.addConsent("general");
    individual.addConsent("docs");
    individual.addConsent("creditheader");
    ```

    <Callout icon="bell" color="#FFCA16" iconType="regular">
      Always capture user consent before calling `submit()` or `verify()`.
    </Callout>

    To read more about consent management, read more <a href="/docs/v1/kyc/kyc-info/consent">here.</a>
  </Accordion>
</AccordionGroup>

## Document Management

<Tabs>
  <Tab title="Add Document">
    ```typescript theme={null}
    const document = {
      documentId: "doc123",
      idType: "PASSPORT",
      country: "AUS",
      idNumber: "P123456",
      idExpiry: "2025-12-31"
    };

    individual.addDocument(document);
    ```
  </Tab>

  <Tab title="Update Document">
    ```typescript theme={null}
    individual.updateDocument("doc123", {
      idExpiry: "2026-12-31"
    });
    ```
  </Tab>
</Tabs>

<AccordionGroup>
  <Accordion title="Document Types">
    <CardGroup cols={2}>
      <Card title="Identity Documents" icon="id-card">
        * `PASSPORT`
        * `DRIVERS_LICENCE`
        * `NATIONAL_ID`
        * `MILITARY_ID`
      </Card>

      <Card title="Proof Documents" icon="file-lines">
        * `UTILITY_BILL`
        * `BANK_STATEMENT`
        * `PROOF_OF_ADDRESS`
        * `TAX_STATEMENT`
      </Card>
    </CardGroup>

    To read more about document types, go <a href="/docs/v1/api/kyc-api-endpoints/reference/document/create-document">here.</a>
  </Accordion>
</AccordionGroup>

## Address Management

<CodeGroup>
  ```typescript title="Add Address" theme={null}
  individual.addAddress({
      addressType: 'RESIDENTIAL',
      buildingName: 'Noida',
      country: 'AUS',
      postalCode: '224400',
      state: 'ACT',
      streetName: 'Mock Street',
      streetNumber: '123',
      town: 'Mock town/suburb',
      unitNumber: '1',
  });
  ```

  ```typescript title="Update Address" theme={null}
  individual.updateAddress("address-123", {
    postalCode: "224401",
    streetName: "New Street",
  });
  ```
</CodeGroup>

## Profile Management

<Steps>
  <Step title="Set Profile Type">
    ```typescript theme={null}
    individual.setProfileType('standard_kyc');
    ```

    <Accordion title="Available Profile Types">
      <CardGroup cols={3}>
        <Card title="Standard" icon="user-shield">
          * `standard_kyc`
          * `gov_id`
          * `safe_harbour`
        </Card>

        <Card title="Enhanced" icon="user-check">
          * `international`
          * `safe_harbour_plus`
          * `full`
        </Card>

        <Card title="Specialized" icon="user-gear">
          * `under18`
          * `devicecheck`
          * `aml_only`
        </Card>
      </CardGroup>
    </Accordion>
  </Step>

  <Step title="Add Reference (Optional)">
    ```typescript theme={null}
    individual.addReference("customer-id", "REF123");
    ```
  </Step>

  <Step title="Set Contact Information">
    ```typescript theme={null}
    individual.setPhoneNumber("+61412345678");
    individual.setEmail("user@example.com");
    ```
  </Step>

  <Step title="Submit Profile">
    ```typescript theme={null}
    await individual.submit();

    // to submit profile and run check
    await individual.submit({ verify: true });
    ```
  </Step>

  <Step title="Run Check">
    ```typescript theme={null}
    // to only run check to entity without submitting
    await individual.runCheck();
    ```
  </Step>
</Steps>

## Add Extra KVP

If you want to set an additional KVPs to an entity, you can use `.setExtraData`
Read more about KVP [here <Icon icon="arrow-up-right-from-square" size={12} />](https://apidocs.frankiefinancial.com/docs/key-value-pairs#kvp-types).
`.setExtraData` accepts an object with key of string and value of string

```typescript title="Setting up KVPs" theme={null}
individual.setExtraData({
  key: 'value',
  extraInformation: 'foo-bar'
})
```

<Callout icon="star" color="#3DD892" iconType="regular">
  Always validate required fields and ensure user consent is captured before
  submitting the profile.
</Callout>
