# Note

## Get note field definitions

`$ lightfield note definitions`

**get** `/v1/notes/definitions`

Returns the schema for the field and relationship definitions available on notes. Useful for understanding the shape of note data before creating or updating records. See <u>[Fields and relationships](/using-the-api/fields-and-relationships/)</u> for more details.

**[Required scope](/using-the-api/scopes/):** `notes:read`

**[Rate limit category](/using-the-api/rate-limits/):** Read

### Returns

- `note_definitions_response: object { fieldDefinitions, objectType, relationshipDefinitions }`

  - `fieldDefinitions: map[object { description, label, typeConfiguration, 3 more } ]`

    Map of field keys to their definitions, including both system and custom fields.

    - `description: string`

      Description of the field, or null.

    - `label: string`

      Human-readable display name of the field.

    - `typeConfiguration: object { currency, handleService, multipleValues, 3 more }`

      Type-specific configuration (e.g. select options, currency code).

      - `currency: optional string`

        ISO 4217 3-letter currency code.

      - `handleService: optional "TWITTER" or "LINKEDIN" or "FACEBOOK" or "INSTAGRAM"`

        Social platform associated with this handle field.

        - `"TWITTER"`

        - `"LINKEDIN"`

        - `"FACEBOOK"`

        - `"INSTAGRAM"`

      - `multipleValues: optional boolean`

        Whether this field accepts multiple values.

      - `options: optional array of object { id, label, description, parentId }`

        Available options for select fields.

        - `id: string`

          Unique identifier of the select option.

        - `label: string`

          Human-readable display name of the option.

        - `description: optional string`

          Description of the option, or null.

        - `parentId: optional string`

          For a dependent select, the ID of the option in the parent field named by `typeConfiguration.parentFieldKey` that owns this option. Absent for ordinary selects.

      - `parentFieldKey: optional string`

        For a dependent select, the field key whose selected option determines which of this field's options apply. Absent for ordinary selects.

      - `unique: optional boolean`

        Whether values for this field must be unique.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      Data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

    - `id: optional string`

      Unique identifier of the field definition.

    - `readOnly: optional boolean`

      `true` for fields that are not writable via the API (e.g. AI-generated summaries). `false` or absent for writable fields.

  - `objectType: string`

    The object type these definitions belong to (e.g. `account`).

  - `relationshipDefinitions: map[object { cardinality, description, label, 3 more } ]`

    Map of relationship keys to their definitions. Self-referential relationships include optional directional metadata on the bare definition.

    - `cardinality: "HAS_ONE" or "HAS_MANY"`

      Whether this is a `has_one` or `has_many` relationship.

      - `"HAS_ONE"`

      - `"HAS_MANY"`

    - `description: string`

      Description of the relationship, or null.

    - `label: string`

      Human-readable display name of the relationship.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `id: optional string`

      Unique identifier of the relationship definition.

    - `directions: optional object { asDestination, asSource }`

      Directional metadata for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, label }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `label: string`

          Human-readable display name for this endpoint direction.

      - `asSource: object { cardinality, label }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `label: string`

          Human-readable display name for this endpoint direction.

### Example

```cli
lightfield note definitions \
  --api-key 'My API Key'
```

#### Response

```json
{
  "fieldDefinitions": {
    "foo": {
      "description": "description",
      "label": "label",
      "typeConfiguration": {
        "currency": "currency",
        "handleService": "TWITTER",
        "multipleValues": true,
        "options": [
          {
            "id": "id",
            "label": "label",
            "description": "description",
            "parentId": "parentId"
          }
        ],
        "parentFieldKey": "parentFieldKey",
        "unique": true
      },
      "valueType": "ADDRESS",
      "id": "id",
      "readOnly": true
    }
  },
  "objectType": "objectType",
  "relationshipDefinitions": {
    "foo": {
      "cardinality": "HAS_ONE",
      "description": "description",
      "label": "label",
      "objectType": "objectType",
      "id": "id",
      "directions": {
        "asDestination": {
          "cardinality": "HAS_ONE",
          "label": "label"
        },
        "asSource": {
          "cardinality": "HAS_ONE",
          "label": "label"
        }
      }
    }
  }
}
```

## Create a note

`$ lightfield note create`

**post** `/v1/notes`

Creates a new note record.

The note author is automatically set to the API key owner.

Supports idempotency via the `Idempotency-Key` header.

**[Required scope](/using-the-api/scopes/):** `notes:create`

**[Rate limit category](/using-the-api/rate-limits/):** Write

### Parameters

- `--fields: object { "$title", "$content" }`

  Field values for the new note. `$title` is required; `$content` is optional. See **[Fields and relationships](/using-the-api/fields-and-relationships/)** for value type details.

- `--relationships: optional object { "$account", "$contact", "$meeting", "$opportunity" }`

  Relationships to set on the new note. System relationships use a `$` prefix (e.g. `$account`, `$opportunity`, `$contact`, `$meeting`); custom relationships use their bare slug. Each value is a single entity ID or an array of IDs. The note author is automatically set to the API key owner.

### Returns

- `note_create_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Example

```cli
lightfield note create \
  --api-key 'My API Key' \
  --fields '{$title: $title}'
```

#### Response

```json
{
  "id": "id",
  "createdAt": "createdAt",
  "fields": {
    "foo": {
      "value": "string",
      "valueType": "ADDRESS"
    }
  },
  "httpLink": "httpLink",
  "relationships": {
    "foo": {
      "cardinality": "cardinality",
      "objectType": "objectType",
      "values": [
        "string"
      ],
      "directions": {
        "asDestination": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        },
        "asSource": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        }
      }
    }
  },
  "updatedAt": "updatedAt",
  "externalId": "externalId"
}
```

## Update a note

`$ lightfield note update`

**post** `/v1/notes/{id}`

Updates an existing note by ID. Only included fields and relationships are modified.

`$account`, `$opportunity`, `$contact`, and `$meeting` relationships can be modified via `add` and/or `remove` operations (combined in one call or separately).

Supports idempotency via the `Idempotency-Key` header.

**[Required scope](/using-the-api/scopes/):** `notes:update`

**[Rate limit category](/using-the-api/rate-limits/):** Write

### Parameters

- `--id: string`

  Unique identifier of the note to update.

- `--fields: optional object { "$content", "$title" }`

  Field values to update — only provided fields are modified; omitted fields are left unchanged. See **[Fields and relationships](/using-the-api/fields-and-relationships/)** for value type details.

- `--relationships: optional object { "$account", "$contact", "$meeting", "$opportunity" }`

  Relationship operations to apply. System relationships use a `$` prefix (e.g. `$account`, `$opportunity`, `$contact`, `$meeting`); custom relationships use their bare slug. Each value is an operation object with `add` and/or `remove`. `replace` is not supported since note relationships are HAS_MANY.

### Returns

- `note_update_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Example

```cli
lightfield note update \
  --api-key 'My API Key' \
  --id id
```

#### Response

```json
{
  "id": "id",
  "createdAt": "createdAt",
  "fields": {
    "foo": {
      "value": "string",
      "valueType": "ADDRESS"
    }
  },
  "httpLink": "httpLink",
  "relationships": {
    "foo": {
      "cardinality": "cardinality",
      "objectType": "objectType",
      "values": [
        "string"
      ],
      "directions": {
        "asDestination": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        },
        "asSource": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        }
      }
    }
  },
  "updatedAt": "updatedAt",
  "externalId": "externalId"
}
```

## Retrieve a note

`$ lightfield note retrieve`

**get** `/v1/notes/{id}`

Retrieves a single note by its ID.

**[Required scope](/using-the-api/scopes/):** `notes:read`

**[Rate limit category](/using-the-api/rate-limits/):** Read

### Parameters

- `--id: string`

  Unique identifier of the note to retrieve.

### Returns

- `note_retrieve_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Example

```cli
lightfield note retrieve \
  --api-key 'My API Key' \
  --id id
```

#### Response

```json
{
  "id": "id",
  "createdAt": "createdAt",
  "fields": {
    "foo": {
      "value": "string",
      "valueType": "ADDRESS"
    }
  },
  "httpLink": "httpLink",
  "relationships": {
    "foo": {
      "cardinality": "cardinality",
      "objectType": "objectType",
      "values": [
        "string"
      ],
      "directions": {
        "asDestination": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        },
        "asSource": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        }
      }
    }
  },
  "updatedAt": "updatedAt",
  "externalId": "externalId"
}
```

## List notes

`$ lightfield note list`

**get** `/v1/notes`

Returns a paginated list of notes. Results are sorted by when the record was created in Lightfield (`createdAt`), newest first. Use `offset` and `limit` to paginate through results. Pass `status=trashed` to list notes currently in the trash instead of live records. Listing trashed records additionally requires the `notes:restore` scope. See <u>[List endpoints](/using-the-api/list-endpoints/)</u> for more information about pagination.

**[Required scope](/using-the-api/scopes/):** `notes:read`

**[Rate limit category](/using-the-api/rate-limits/):** Search

### Parameters

- `--limit: optional number`

  Maximum number of records to return. Defaults to 25, maximum 25.

- `--offset: optional number`

  Number of records to skip for pagination. Defaults to 0.

- `--status: optional "active" or "trashed"`

  Which records to return by trash state. Defaults to "active". Use "trashed" to list records currently in the trash; this additionally requires this resource's `restore` scope.

### Returns

- `note_list_response: object { data, object, totalCount }`

  - `data: array of object { id, createdAt, fields, 4 more }`

    Array of entity objects for the current page.

    - `id: string`

      Unique identifier for the entity.

    - `createdAt: string`

      ISO 8601 timestamp of when the entity was created.

    - `fields: map[object { value, valueType } ]`

      Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

      - `value: string or number or boolean or 3 more`

        The field value, or null if unset.

        - `union_member_0: string`

        - `union_member_1: number`

        - `union_member_2: boolean`

        - `union_member_3: array of string`

        - `Address: object { city, country, latitude, 5 more }`

          - `city: optional string`

            City name.

          - `country: optional string`

            2-letter ISO 3166-1 alpha-2 country code.

          - `latitude: optional number`

            Latitude coordinate.

          - `longitude: optional number`

            Longitude coordinate.

          - `postalCode: optional string`

            Postal or ZIP code.

          - `state: optional string`

            State or province.

          - `street: optional string`

            Street address line 1.

          - `street2: optional string`

            Street address line 2.

        - `FullName: object { firstName, lastName }`

          - `firstName: optional string`

            The contact's first name.

          - `lastName: optional string`

            The contact's last name.

      - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

        The data type of the field.

        - `"ADDRESS"`

        - `"CHECKBOX"`

        - `"CURRENCY"`

        - `"DATE"`

        - `"DATETIME"`

        - `"EMAIL"`

        - `"FULL_NAME"`

        - `"MARKDOWN"`

        - `"MULTI_SELECT"`

        - `"NUMBER"`

        - `"SINGLE_SELECT"`

        - `"SOCIAL_HANDLE"`

        - `"TELEPHONE"`

        - `"TEXT"`

        - `"URL"`

        - `"HTML"`

    - `httpLink: string`

      URL to view the entity in the Lightfield web app, or null.

    - `relationships: map[object { cardinality, objectType, values, directions } ]`

      Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

      - `cardinality: string`

        Whether the relationship is `has_one` or `has_many`.

      - `objectType: string`

        The type of the related object (e.g. `account`, `contact`).

      - `values: array of string`

        IDs of the related entities.

      - `directions: optional object { asDestination, asSource }`

        Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

        - `asDestination: object { cardinality, values }`

          The current record is the destination (incoming) endpoint.

          - `cardinality: "HAS_ONE" or "HAS_MANY"`

            Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

            - `"HAS_ONE"`

            - `"HAS_MANY"`

          - `values: array of string`

            IDs of the related entities in this direction.

        - `asSource: object { cardinality, values }`

          The current record is the source (outgoing) endpoint.

          - `cardinality: "HAS_ONE" or "HAS_MANY"`

            Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

            - `"HAS_ONE"`

            - `"HAS_MANY"`

          - `values: array of string`

            IDs of the related entities in this direction.

    - `updatedAt: string`

      ISO 8601 timestamp of when the entity was last updated, or null.

    - `externalId: optional string`

      External identifier for the entity, or null if unset.

  - `object: string`

    The object type, always `"list"`.

  - `totalCount: number`

    Total number of entities matching the query.

### Example

```cli
lightfield note list \
  --api-key 'My API Key'
```

#### Response

```json
{
  "data": [
    {
      "id": "id",
      "createdAt": "createdAt",
      "fields": {
        "foo": {
          "value": "string",
          "valueType": "ADDRESS"
        }
      },
      "httpLink": "httpLink",
      "relationships": {
        "foo": {
          "cardinality": "cardinality",
          "objectType": "objectType",
          "values": [
            "string"
          ],
          "directions": {
            "asDestination": {
              "cardinality": "HAS_ONE",
              "values": [
                "string"
              ]
            },
            "asSource": {
              "cardinality": "HAS_ONE",
              "values": [
                "string"
              ]
            }
          }
        }
      },
      "updatedAt": "updatedAt",
      "externalId": "externalId"
    }
  ],
  "object": "object",
  "totalCount": 0
}
```

## Delete a note

`$ lightfield note delete`

**delete** `/v1/notes/{id}`

Moves a note to the trash. The note is soft-deleted and may be restored from the Lightfield UI.

Calling delete on an already-trashed note is a no-op and returns the existing record.

**[Required scope](/using-the-api/scopes/):** `notes:delete`

**[Rate limit category](/using-the-api/rate-limits/):** Write

### Parameters

- `--id: string`

  Unique identifier of the note to delete.

- `--body: optional object {  }`

### Returns

- `note_delete_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Example

```cli
lightfield note delete \
  --api-key 'My API Key' \
  --id id
```

#### Response

```json
{
  "id": "id",
  "createdAt": "createdAt",
  "fields": {
    "foo": {
      "value": "string",
      "valueType": "ADDRESS"
    }
  },
  "httpLink": "httpLink",
  "relationships": {
    "foo": {
      "cardinality": "cardinality",
      "objectType": "objectType",
      "values": [
        "string"
      ],
      "directions": {
        "asDestination": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        },
        "asSource": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        }
      }
    }
  },
  "updatedAt": "updatedAt",
  "externalId": "externalId"
}
```

## Restore a note

`$ lightfield note restore`

**post** `/v1/notes/{id}/restore`

Restores a trashed note, bringing it back to active. Find trashed notes via `GET /v1/notes?status=trashed`.

Calling restore on a note that is not trashed is a no-op and returns the existing record.

**[Required scope](/using-the-api/scopes/):** `notes:restore`

**[Rate limit category](/using-the-api/rate-limits/):** Write

### Parameters

- `--id: string`

  Unique identifier of the note to restore.

- `--body: optional object {  }`

### Returns

- `note_restore_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Example

```cli
lightfield note restore \
  --api-key 'My API Key' \
  --id id
```

#### Response

```json
{
  "id": "id",
  "createdAt": "createdAt",
  "fields": {
    "foo": {
      "value": "string",
      "valueType": "ADDRESS"
    }
  },
  "httpLink": "httpLink",
  "relationships": {
    "foo": {
      "cardinality": "cardinality",
      "objectType": "objectType",
      "values": [
        "string"
      ],
      "directions": {
        "asDestination": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        },
        "asSource": {
          "cardinality": "HAS_ONE",
          "values": [
            "string"
          ]
        }
      }
    }
  },
  "updatedAt": "updatedAt",
  "externalId": "externalId"
}
```

## Domain Types

### Note Create Response

- `note_create_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Note Definitions Response

- `note_definitions_response: object { fieldDefinitions, objectType, relationshipDefinitions }`

  - `fieldDefinitions: map[object { description, label, typeConfiguration, 3 more } ]`

    Map of field keys to their definitions, including both system and custom fields.

    - `description: string`

      Description of the field, or null.

    - `label: string`

      Human-readable display name of the field.

    - `typeConfiguration: object { currency, handleService, multipleValues, 3 more }`

      Type-specific configuration (e.g. select options, currency code).

      - `currency: optional string`

        ISO 4217 3-letter currency code.

      - `handleService: optional "TWITTER" or "LINKEDIN" or "FACEBOOK" or "INSTAGRAM"`

        Social platform associated with this handle field.

        - `"TWITTER"`

        - `"LINKEDIN"`

        - `"FACEBOOK"`

        - `"INSTAGRAM"`

      - `multipleValues: optional boolean`

        Whether this field accepts multiple values.

      - `options: optional array of object { id, label, description, parentId }`

        Available options for select fields.

        - `id: string`

          Unique identifier of the select option.

        - `label: string`

          Human-readable display name of the option.

        - `description: optional string`

          Description of the option, or null.

        - `parentId: optional string`

          For a dependent select, the ID of the option in the parent field named by `typeConfiguration.parentFieldKey` that owns this option. Absent for ordinary selects.

      - `parentFieldKey: optional string`

        For a dependent select, the field key whose selected option determines which of this field's options apply. Absent for ordinary selects.

      - `unique: optional boolean`

        Whether values for this field must be unique.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      Data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

    - `id: optional string`

      Unique identifier of the field definition.

    - `readOnly: optional boolean`

      `true` for fields that are not writable via the API (e.g. AI-generated summaries). `false` or absent for writable fields.

  - `objectType: string`

    The object type these definitions belong to (e.g. `account`).

  - `relationshipDefinitions: map[object { cardinality, description, label, 3 more } ]`

    Map of relationship keys to their definitions. Self-referential relationships include optional directional metadata on the bare definition.

    - `cardinality: "HAS_ONE" or "HAS_MANY"`

      Whether this is a `has_one` or `has_many` relationship.

      - `"HAS_ONE"`

      - `"HAS_MANY"`

    - `description: string`

      Description of the relationship, or null.

    - `label: string`

      Human-readable display name of the relationship.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `id: optional string`

      Unique identifier of the relationship definition.

    - `directions: optional object { asDestination, asSource }`

      Directional metadata for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, label }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `label: string`

          Human-readable display name for this endpoint direction.

      - `asSource: object { cardinality, label }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `label: string`

          Human-readable display name for this endpoint direction.

### Note Delete Response

- `note_delete_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Note List Response

- `note_list_response: object { data, object, totalCount }`

  - `data: array of object { id, createdAt, fields, 4 more }`

    Array of entity objects for the current page.

    - `id: string`

      Unique identifier for the entity.

    - `createdAt: string`

      ISO 8601 timestamp of when the entity was created.

    - `fields: map[object { value, valueType } ]`

      Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

      - `value: string or number or boolean or 3 more`

        The field value, or null if unset.

        - `union_member_0: string`

        - `union_member_1: number`

        - `union_member_2: boolean`

        - `union_member_3: array of string`

        - `Address: object { city, country, latitude, 5 more }`

          - `city: optional string`

            City name.

          - `country: optional string`

            2-letter ISO 3166-1 alpha-2 country code.

          - `latitude: optional number`

            Latitude coordinate.

          - `longitude: optional number`

            Longitude coordinate.

          - `postalCode: optional string`

            Postal or ZIP code.

          - `state: optional string`

            State or province.

          - `street: optional string`

            Street address line 1.

          - `street2: optional string`

            Street address line 2.

        - `FullName: object { firstName, lastName }`

          - `firstName: optional string`

            The contact's first name.

          - `lastName: optional string`

            The contact's last name.

      - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

        The data type of the field.

        - `"ADDRESS"`

        - `"CHECKBOX"`

        - `"CURRENCY"`

        - `"DATE"`

        - `"DATETIME"`

        - `"EMAIL"`

        - `"FULL_NAME"`

        - `"MARKDOWN"`

        - `"MULTI_SELECT"`

        - `"NUMBER"`

        - `"SINGLE_SELECT"`

        - `"SOCIAL_HANDLE"`

        - `"TELEPHONE"`

        - `"TEXT"`

        - `"URL"`

        - `"HTML"`

    - `httpLink: string`

      URL to view the entity in the Lightfield web app, or null.

    - `relationships: map[object { cardinality, objectType, values, directions } ]`

      Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

      - `cardinality: string`

        Whether the relationship is `has_one` or `has_many`.

      - `objectType: string`

        The type of the related object (e.g. `account`, `contact`).

      - `values: array of string`

        IDs of the related entities.

      - `directions: optional object { asDestination, asSource }`

        Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

        - `asDestination: object { cardinality, values }`

          The current record is the destination (incoming) endpoint.

          - `cardinality: "HAS_ONE" or "HAS_MANY"`

            Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

            - `"HAS_ONE"`

            - `"HAS_MANY"`

          - `values: array of string`

            IDs of the related entities in this direction.

        - `asSource: object { cardinality, values }`

          The current record is the source (outgoing) endpoint.

          - `cardinality: "HAS_ONE" or "HAS_MANY"`

            Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

            - `"HAS_ONE"`

            - `"HAS_MANY"`

          - `values: array of string`

            IDs of the related entities in this direction.

    - `updatedAt: string`

      ISO 8601 timestamp of when the entity was last updated, or null.

    - `externalId: optional string`

      External identifier for the entity, or null if unset.

  - `object: string`

    The object type, always `"list"`.

  - `totalCount: number`

    Total number of entities matching the query.

### Note Restore Response

- `note_restore_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Note Retrieve Response

- `note_retrieve_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.

### Note Update Response

- `note_update_response: object { id, createdAt, fields, 4 more }`

  - `id: string`

    Unique identifier for the entity.

  - `createdAt: string`

    ISO 8601 timestamp of when the entity was created.

  - `fields: map[object { value, valueType } ]`

    Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.

    - `value: string or number or boolean or 3 more`

      The field value, or null if unset.

      - `union_member_0: string`

      - `union_member_1: number`

      - `union_member_2: boolean`

      - `union_member_3: array of string`

      - `Address: object { city, country, latitude, 5 more }`

        - `city: optional string`

          City name.

        - `country: optional string`

          2-letter ISO 3166-1 alpha-2 country code.

        - `latitude: optional number`

          Latitude coordinate.

        - `longitude: optional number`

          Longitude coordinate.

        - `postalCode: optional string`

          Postal or ZIP code.

        - `state: optional string`

          State or province.

        - `street: optional string`

          Street address line 1.

        - `street2: optional string`

          Street address line 2.

      - `FullName: object { firstName, lastName }`

        - `firstName: optional string`

          The contact's first name.

        - `lastName: optional string`

          The contact's last name.

    - `valueType: "ADDRESS" or "CHECKBOX" or "CURRENCY" or 13 more`

      The data type of the field.

      - `"ADDRESS"`

      - `"CHECKBOX"`

      - `"CURRENCY"`

      - `"DATE"`

      - `"DATETIME"`

      - `"EMAIL"`

      - `"FULL_NAME"`

      - `"MARKDOWN"`

      - `"MULTI_SELECT"`

      - `"NUMBER"`

      - `"SINGLE_SELECT"`

      - `"SOCIAL_HANDLE"`

      - `"TELEPHONE"`

      - `"TEXT"`

      - `"URL"`

      - `"HTML"`

  - `httpLink: string`

    URL to view the entity in the Lightfield web app, or null.

  - `relationships: map[object { cardinality, objectType, values, directions } ]`

    Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`). A self-referential relationship keeps its merged values and includes optional directional values. List filters select the current record's role with `:asSource` or `:asDestination`, for example `?parent:asSource[contains]=account_id`.

    - `cardinality: string`

      Whether the relationship is `has_one` or `has_many`.

    - `objectType: string`

      The type of the related object (e.g. `account`, `contact`).

    - `values: array of string`

      IDs of the related entities.

    - `directions: optional object { asDestination, asSource }`

      Directional values for a self-referential relationship. List filters use the relationship key with `:asSource` or `:asDestination`; writes continue to use the bare key.

      - `asDestination: object { cardinality, values }`

        The current record is the destination (incoming) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

      - `asSource: object { cardinality, values }`

        The current record is the source (outgoing) endpoint.

        - `cardinality: "HAS_ONE" or "HAS_MANY"`

          Whether this endpoint direction is `HAS_ONE` or `HAS_MANY`.

          - `"HAS_ONE"`

          - `"HAS_MANY"`

        - `values: array of string`

          IDs of the related entities in this direction.

  - `updatedAt: string`

    ISO 8601 timestamp of when the entity was last updated, or null.

  - `externalId: optional string`

    External identifier for the entity, or null if unset.
