# Contact
## Get contact field definitions
`client.Contact.Definitions(ctx) (*ContactDefinitionsResponse, error)`
**get** `/v1/contacts/definitions`
Returns the schema for all field and relationship definitions available on contacts, including both system-defined and custom fields. Useful for understanding the shape of contact data before creating or updating records. See [Fields and relationships](/using-the-api/fields-and-relationships/) for more details.
**[Required scope](/using-the-api/scopes/):** `contacts:read`
**[Rate limit category](/using-the-api/rate-limits/):** Read
### Returns
- `type ContactDefinitionsResponse struct{…}`
- `FieldDefinitions map[string, ContactDefinitionsResponseFieldDefinition]`
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 ContactDefinitionsResponseFieldDefinitionTypeConfiguration`
Type-specific configuration (e.g. select options, currency code).
- `Currency string`
ISO 4217 3-letter currency code.
- `HandleService string`
Social platform associated with this handle field.
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceTwitter ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "TWITTER"`
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceLinkedin ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "LINKEDIN"`
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceFacebook ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "FACEBOOK"`
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceInstagram ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "INSTAGRAM"`
- `MultipleValues bool`
Whether this field accepts multiple values.
- `Options []ContactDefinitionsResponseFieldDefinitionTypeConfigurationOption`
Available options for select fields.
- `ID string`
Unique identifier of the select option.
- `Label string`
Human-readable display name of the option.
- `Description string`
Description of the option, or null.
- `Unique bool`
Whether values for this field must be unique.
- `ValueType string`
Data type of the field.
- `const ContactDefinitionsResponseFieldDefinitionValueTypeAddress ContactDefinitionsResponseFieldDefinitionValueType = "ADDRESS"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeCheckbox ContactDefinitionsResponseFieldDefinitionValueType = "CHECKBOX"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeCurrency ContactDefinitionsResponseFieldDefinitionValueType = "CURRENCY"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeDatetime ContactDefinitionsResponseFieldDefinitionValueType = "DATETIME"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeEmail ContactDefinitionsResponseFieldDefinitionValueType = "EMAIL"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeFullName ContactDefinitionsResponseFieldDefinitionValueType = "FULL_NAME"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeMarkdown ContactDefinitionsResponseFieldDefinitionValueType = "MARKDOWN"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeMultiSelect ContactDefinitionsResponseFieldDefinitionValueType = "MULTI_SELECT"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeNumber ContactDefinitionsResponseFieldDefinitionValueType = "NUMBER"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeSingleSelect ContactDefinitionsResponseFieldDefinitionValueType = "SINGLE_SELECT"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeSocialHandle ContactDefinitionsResponseFieldDefinitionValueType = "SOCIAL_HANDLE"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeTelephone ContactDefinitionsResponseFieldDefinitionValueType = "TELEPHONE"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeText ContactDefinitionsResponseFieldDefinitionValueType = "TEXT"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeURL ContactDefinitionsResponseFieldDefinitionValueType = "URL"`
- `ID string`
Unique identifier of the field definition.
- `ReadOnly bool`
`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[string, ContactDefinitionsResponseRelationshipDefinition]`
Map of relationship keys to their definitions.
- `Cardinality string`
Whether this is a `has_one` or `has_many` relationship.
- `const ContactDefinitionsResponseRelationshipDefinitionCardinalityHasOne ContactDefinitionsResponseRelationshipDefinitionCardinality = "HAS_ONE"`
- `const ContactDefinitionsResponseRelationshipDefinitionCardinalityHasMany ContactDefinitionsResponseRelationshipDefinitionCardinality = "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 string`
Unique identifier of the relationship definition.
### Example
```go
package main
import (
"context"
"fmt"
"github.com/Lightfld/lightfield-go"
"github.com/Lightfld/lightfield-go/option"
)
func main() {
client := githubcomlightfldlightfieldgo.NewClient(
option.WithAPIKey("My API Key"),
)
contactDefinitionsResponse, err := client.Contact.Definitions(context.TODO())
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", contactDefinitionsResponse.FieldDefinitions)
}
```
#### Response
```json
{
"fieldDefinitions": {
"foo": {
"description": "description",
"label": "label",
"typeConfiguration": {
"currency": "currency",
"handleService": "TWITTER",
"multipleValues": true,
"options": [
{
"id": "id",
"label": "label",
"description": "description"
}
],
"unique": true
},
"valueType": "ADDRESS",
"id": "id",
"readOnly": true
}
},
"objectType": "objectType",
"relationshipDefinitions": {
"foo": {
"cardinality": "HAS_ONE",
"description": "description",
"label": "label",
"objectType": "objectType",
"id": "id"
}
}
}
```
## Create a contact
`client.Contact.New(ctx, body) (*ContactCreateResponse, error)`
**post** `/v1/contacts`
Creates a new contact record.
After creation, Lightfield automatically enriches the contact in the background.
Supports idempotency via the `Idempotency-Key` header.
To avoid duplicates, we recommend a find-or-create pattern — use [list filtering](/using-the-api/list-endpoints/#filtering) to check if a record exists before creating.
**[Required scope](/using-the-api/scopes/):** `contacts:create`
**[Rate limit category](/using-the-api/rate-limits/):** Write
### Parameters
- `body ContactNewParams`
- `Fields param.Field[map[string, ContactNewParamsFieldUnion]]`
Field values for the new contact. System fields use a `$` prefix (e.g. `$email`, `$name`); custom attributes use their bare slug. Note: `$name` is an object `{ firstName, lastName }`, not a plain string. Call the [definitions endpoint](/api/resources/contact/methods/definitions) to discover available fields and their types. See [Fields and relationships](/using-the-api/fields-and-relationships/) for value type details.
- `map[string, ContactNewParamsFieldUnion]`
- `string`
- `float64`
- `bool`
- `type ContactNewParamsFieldArray []string`
- `type ContactNewParamsFieldAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactNewParamsFieldFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `Relationships param.Field[map[string, ContactNewParamsRelationshipUnion]]`
Relationships to set on the new contact. System relationships use a `$` prefix (e.g. `$account`); custom relationships use their bare slug. Each value is a single entity ID or an array of IDs. Call the [definitions endpoint](/api/resources/contact/methods/definitions) to list available relationship keys.
- `map[string, ContactNewParamsRelationshipUnion]`
- `string`
- `type ContactNewParamsRelationshipArray []string`
### Returns
- `type ContactCreateResponse struct{…}`
- `ID string`
Unique identifier for the entity.
- `CreatedAt string`
ISO 8601 timestamp of when the entity was created.
- `Fields map[string, ContactCreateResponseField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactCreateResponseFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactCreateResponseFieldValueArray []string`
- `type ContactCreateResponseFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactCreateResponseFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactCreateResponseFieldValueTypeAddress ContactCreateResponseFieldValueType = "ADDRESS"`
- `const ContactCreateResponseFieldValueTypeCheckbox ContactCreateResponseFieldValueType = "CHECKBOX"`
- `const ContactCreateResponseFieldValueTypeCurrency ContactCreateResponseFieldValueType = "CURRENCY"`
- `const ContactCreateResponseFieldValueTypeDatetime ContactCreateResponseFieldValueType = "DATETIME"`
- `const ContactCreateResponseFieldValueTypeEmail ContactCreateResponseFieldValueType = "EMAIL"`
- `const ContactCreateResponseFieldValueTypeFullName ContactCreateResponseFieldValueType = "FULL_NAME"`
- `const ContactCreateResponseFieldValueTypeMarkdown ContactCreateResponseFieldValueType = "MARKDOWN"`
- `const ContactCreateResponseFieldValueTypeMultiSelect ContactCreateResponseFieldValueType = "MULTI_SELECT"`
- `const ContactCreateResponseFieldValueTypeNumber ContactCreateResponseFieldValueType = "NUMBER"`
- `const ContactCreateResponseFieldValueTypeSingleSelect ContactCreateResponseFieldValueType = "SINGLE_SELECT"`
- `const ContactCreateResponseFieldValueTypeSocialHandle ContactCreateResponseFieldValueType = "SOCIAL_HANDLE"`
- `const ContactCreateResponseFieldValueTypeTelephone ContactCreateResponseFieldValueType = "TELEPHONE"`
- `const ContactCreateResponseFieldValueTypeText ContactCreateResponseFieldValueType = "TEXT"`
- `const ContactCreateResponseFieldValueTypeURL ContactCreateResponseFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactCreateResponseRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
### Example
```go
package main
import (
"context"
"fmt"
"github.com/Lightfld/lightfield-go"
"github.com/Lightfld/lightfield-go/option"
)
func main() {
client := githubcomlightfldlightfieldgo.NewClient(
option.WithAPIKey("My API Key"),
)
contactCreateResponse, err := client.Contact.New(context.TODO(), githubcomlightfldlightfieldgo.ContactNewParams{
Fields: map[string]githubcomlightfldlightfieldgo.ContactNewParamsFieldUnion{
"foo": githubcomlightfldlightfieldgo.ContactNewParamsFieldUnion{
OfString: githubcomlightfldlightfieldgo.String("string"),
},
},
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", contactCreateResponse.ID)
}
```
#### Response
```json
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
},
"updatedAt": "updatedAt",
"externalId": "externalId"
}
```
## Update a contact
`client.Contact.Update(ctx, id, body) (*ContactUpdateResponse, error)`
**post** `/v1/contacts/{id}`
Updates an existing contact by ID. Only included fields and relationships are modified.
Supports idempotency via the `Idempotency-Key` header.
**[Required scope](/using-the-api/scopes/):** `contacts:update`
**[Rate limit category](/using-the-api/rate-limits/):** Write
### Parameters
- `id string`
Unique identifier of the contact to update.
- `body ContactUpdateParams`
- `Fields param.Field[map[string, ContactUpdateParamsFieldUnion]]`
Field values to update — only provided fields are modified; omitted fields are left unchanged. System fields use a `$` prefix (e.g. `$email`); custom attributes use their bare slug. Note: `$name` is an object `{ firstName, lastName }`, not a plain string. Call the [definitions endpoint](/api/resources/contact/methods/definitions) for available fields and types. See [Fields and relationships](/using-the-api/fields-and-relationships/) for value type details.
- `map[string, ContactUpdateParamsFieldUnion]`
- `string`
- `float64`
- `bool`
- `type ContactUpdateParamsFieldArray []string`
- `type ContactUpdateParamsFieldAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactUpdateParamsFieldFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `Relationships param.Field[map[string, ContactUpdateParamsRelationship]]`
Relationship operations to apply. System relationships use a `$` prefix (e.g. `$account`). Each value is an operation object with `add`, `remove`, or `replace`.
- `map[string, ContactUpdateParamsRelationship]`
- `Add ContactUpdateParamsRelationshipAddUnion`
Entity ID(s) to add to the relationship.
- `string`
- `type ContactUpdateParamsRelationshipAddArray []string`
- `Remove ContactUpdateParamsRelationshipRemoveUnion`
Entity ID(s) to remove from the relationship.
- `string`
- `type ContactUpdateParamsRelationshipRemoveArray []string`
- `Replace ContactUpdateParamsRelationshipReplaceUnion`
Entity ID(s) to set as the entire relationship, replacing all existing associations.
- `string`
- `type ContactUpdateParamsRelationshipReplaceArray []string`
### Returns
- `type ContactUpdateResponse struct{…}`
- `ID string`
Unique identifier for the entity.
- `CreatedAt string`
ISO 8601 timestamp of when the entity was created.
- `Fields map[string, ContactUpdateResponseField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactUpdateResponseFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactUpdateResponseFieldValueArray []string`
- `type ContactUpdateResponseFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactUpdateResponseFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactUpdateResponseFieldValueTypeAddress ContactUpdateResponseFieldValueType = "ADDRESS"`
- `const ContactUpdateResponseFieldValueTypeCheckbox ContactUpdateResponseFieldValueType = "CHECKBOX"`
- `const ContactUpdateResponseFieldValueTypeCurrency ContactUpdateResponseFieldValueType = "CURRENCY"`
- `const ContactUpdateResponseFieldValueTypeDatetime ContactUpdateResponseFieldValueType = "DATETIME"`
- `const ContactUpdateResponseFieldValueTypeEmail ContactUpdateResponseFieldValueType = "EMAIL"`
- `const ContactUpdateResponseFieldValueTypeFullName ContactUpdateResponseFieldValueType = "FULL_NAME"`
- `const ContactUpdateResponseFieldValueTypeMarkdown ContactUpdateResponseFieldValueType = "MARKDOWN"`
- `const ContactUpdateResponseFieldValueTypeMultiSelect ContactUpdateResponseFieldValueType = "MULTI_SELECT"`
- `const ContactUpdateResponseFieldValueTypeNumber ContactUpdateResponseFieldValueType = "NUMBER"`
- `const ContactUpdateResponseFieldValueTypeSingleSelect ContactUpdateResponseFieldValueType = "SINGLE_SELECT"`
- `const ContactUpdateResponseFieldValueTypeSocialHandle ContactUpdateResponseFieldValueType = "SOCIAL_HANDLE"`
- `const ContactUpdateResponseFieldValueTypeTelephone ContactUpdateResponseFieldValueType = "TELEPHONE"`
- `const ContactUpdateResponseFieldValueTypeText ContactUpdateResponseFieldValueType = "TEXT"`
- `const ContactUpdateResponseFieldValueTypeURL ContactUpdateResponseFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactUpdateResponseRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
### Example
```go
package main
import (
"context"
"fmt"
"github.com/Lightfld/lightfield-go"
"github.com/Lightfld/lightfield-go/option"
)
func main() {
client := githubcomlightfldlightfieldgo.NewClient(
option.WithAPIKey("My API Key"),
)
contactUpdateResponse, err := client.Contact.Update(
context.TODO(),
"id",
githubcomlightfldlightfieldgo.ContactUpdateParams{
},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", contactUpdateResponse.ID)
}
```
#### Response
```json
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
},
"updatedAt": "updatedAt",
"externalId": "externalId"
}
```
## Retrieve a contact
`client.Contact.Get(ctx, id) (*ContactRetrieveResponse, error)`
**get** `/v1/contacts/{id}`
Retrieves a single contact by its ID.
**[Required scope](/using-the-api/scopes/):** `contacts:read`
**[Rate limit category](/using-the-api/rate-limits/):** Read
### Parameters
- `id string`
Unique identifier of the contact to retrieve.
### Returns
- `type ContactRetrieveResponse struct{…}`
- `ID string`
Unique identifier for the entity.
- `CreatedAt string`
ISO 8601 timestamp of when the entity was created.
- `Fields map[string, ContactRetrieveResponseField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactRetrieveResponseFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactRetrieveResponseFieldValueArray []string`
- `type ContactRetrieveResponseFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactRetrieveResponseFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactRetrieveResponseFieldValueTypeAddress ContactRetrieveResponseFieldValueType = "ADDRESS"`
- `const ContactRetrieveResponseFieldValueTypeCheckbox ContactRetrieveResponseFieldValueType = "CHECKBOX"`
- `const ContactRetrieveResponseFieldValueTypeCurrency ContactRetrieveResponseFieldValueType = "CURRENCY"`
- `const ContactRetrieveResponseFieldValueTypeDatetime ContactRetrieveResponseFieldValueType = "DATETIME"`
- `const ContactRetrieveResponseFieldValueTypeEmail ContactRetrieveResponseFieldValueType = "EMAIL"`
- `const ContactRetrieveResponseFieldValueTypeFullName ContactRetrieveResponseFieldValueType = "FULL_NAME"`
- `const ContactRetrieveResponseFieldValueTypeMarkdown ContactRetrieveResponseFieldValueType = "MARKDOWN"`
- `const ContactRetrieveResponseFieldValueTypeMultiSelect ContactRetrieveResponseFieldValueType = "MULTI_SELECT"`
- `const ContactRetrieveResponseFieldValueTypeNumber ContactRetrieveResponseFieldValueType = "NUMBER"`
- `const ContactRetrieveResponseFieldValueTypeSingleSelect ContactRetrieveResponseFieldValueType = "SINGLE_SELECT"`
- `const ContactRetrieveResponseFieldValueTypeSocialHandle ContactRetrieveResponseFieldValueType = "SOCIAL_HANDLE"`
- `const ContactRetrieveResponseFieldValueTypeTelephone ContactRetrieveResponseFieldValueType = "TELEPHONE"`
- `const ContactRetrieveResponseFieldValueTypeText ContactRetrieveResponseFieldValueType = "TEXT"`
- `const ContactRetrieveResponseFieldValueTypeURL ContactRetrieveResponseFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactRetrieveResponseRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
### Example
```go
package main
import (
"context"
"fmt"
"github.com/Lightfld/lightfield-go"
"github.com/Lightfld/lightfield-go/option"
)
func main() {
client := githubcomlightfldlightfieldgo.NewClient(
option.WithAPIKey("My API Key"),
)
contactRetrieveResponse, err := client.Contact.Get(context.TODO(), "id")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", contactRetrieveResponse.ID)
}
```
#### Response
```json
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
},
"updatedAt": "updatedAt",
"externalId": "externalId"
}
```
## List contacts
`client.Contact.List(ctx, query) (*ContactListResponse, error)`
**get** `/v1/contacts`
Returns a paginated list of contacts. Use `offset` and `limit` to paginate through results, and `$field` query parameters to filter. See [List endpoints](/using-the-api/list-endpoints/) for more information about [pagination](/using-the-api/list-endpoints/#pagination) and [filtering](/using-the-api/list-endpoints/#filtering).
**[Required scope](/using-the-api/scopes/):** `contacts:read`
**[Rate limit category](/using-the-api/rate-limits/):** Search
### Parameters
- `query ContactListParams`
- `Limit param.Field[int64]`
Maximum number of records to return. Defaults to 25, maximum 25.
- `Offset param.Field[int64]`
Number of records to skip for pagination. Defaults to 0.
### Returns
- `type ContactListResponse struct{…}`
- `Data []ContactListResponseData`
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[string, ContactListResponseDataField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactListResponseDataFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactListResponseDataFieldValueArray []string`
- `type ContactListResponseDataFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactListResponseDataFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactListResponseDataFieldValueTypeAddress ContactListResponseDataFieldValueType = "ADDRESS"`
- `const ContactListResponseDataFieldValueTypeCheckbox ContactListResponseDataFieldValueType = "CHECKBOX"`
- `const ContactListResponseDataFieldValueTypeCurrency ContactListResponseDataFieldValueType = "CURRENCY"`
- `const ContactListResponseDataFieldValueTypeDatetime ContactListResponseDataFieldValueType = "DATETIME"`
- `const ContactListResponseDataFieldValueTypeEmail ContactListResponseDataFieldValueType = "EMAIL"`
- `const ContactListResponseDataFieldValueTypeFullName ContactListResponseDataFieldValueType = "FULL_NAME"`
- `const ContactListResponseDataFieldValueTypeMarkdown ContactListResponseDataFieldValueType = "MARKDOWN"`
- `const ContactListResponseDataFieldValueTypeMultiSelect ContactListResponseDataFieldValueType = "MULTI_SELECT"`
- `const ContactListResponseDataFieldValueTypeNumber ContactListResponseDataFieldValueType = "NUMBER"`
- `const ContactListResponseDataFieldValueTypeSingleSelect ContactListResponseDataFieldValueType = "SINGLE_SELECT"`
- `const ContactListResponseDataFieldValueTypeSocialHandle ContactListResponseDataFieldValueType = "SOCIAL_HANDLE"`
- `const ContactListResponseDataFieldValueTypeTelephone ContactListResponseDataFieldValueType = "TELEPHONE"`
- `const ContactListResponseDataFieldValueTypeText ContactListResponseDataFieldValueType = "TEXT"`
- `const ContactListResponseDataFieldValueTypeURL ContactListResponseDataFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactListResponseDataRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
- `Object string`
The object type, always `"list"`.
- `TotalCount int64`
Total number of entities matching the query.
### Example
```go
package main
import (
"context"
"fmt"
"github.com/Lightfld/lightfield-go"
"github.com/Lightfld/lightfield-go/option"
)
func main() {
client := githubcomlightfldlightfieldgo.NewClient(
option.WithAPIKey("My API Key"),
)
contactListResponse, err := client.Contact.List(context.TODO(), githubcomlightfldlightfieldgo.ContactListParams{
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", contactListResponse.Data)
}
```
#### Response
```json
{
"data": [
{
"id": "id",
"createdAt": "createdAt",
"fields": {
"foo": {
"value": "string",
"valueType": "ADDRESS"
}
},
"httpLink": "httpLink",
"relationships": {
"foo": {
"cardinality": "cardinality",
"objectType": "objectType",
"values": [
"string"
]
}
},
"updatedAt": "updatedAt",
"externalId": "externalId"
}
],
"object": "object",
"totalCount": 0
}
```
## Domain Types
### Contact Create Response
- `type ContactCreateResponse struct{…}`
- `ID string`
Unique identifier for the entity.
- `CreatedAt string`
ISO 8601 timestamp of when the entity was created.
- `Fields map[string, ContactCreateResponseField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactCreateResponseFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactCreateResponseFieldValueArray []string`
- `type ContactCreateResponseFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactCreateResponseFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactCreateResponseFieldValueTypeAddress ContactCreateResponseFieldValueType = "ADDRESS"`
- `const ContactCreateResponseFieldValueTypeCheckbox ContactCreateResponseFieldValueType = "CHECKBOX"`
- `const ContactCreateResponseFieldValueTypeCurrency ContactCreateResponseFieldValueType = "CURRENCY"`
- `const ContactCreateResponseFieldValueTypeDatetime ContactCreateResponseFieldValueType = "DATETIME"`
- `const ContactCreateResponseFieldValueTypeEmail ContactCreateResponseFieldValueType = "EMAIL"`
- `const ContactCreateResponseFieldValueTypeFullName ContactCreateResponseFieldValueType = "FULL_NAME"`
- `const ContactCreateResponseFieldValueTypeMarkdown ContactCreateResponseFieldValueType = "MARKDOWN"`
- `const ContactCreateResponseFieldValueTypeMultiSelect ContactCreateResponseFieldValueType = "MULTI_SELECT"`
- `const ContactCreateResponseFieldValueTypeNumber ContactCreateResponseFieldValueType = "NUMBER"`
- `const ContactCreateResponseFieldValueTypeSingleSelect ContactCreateResponseFieldValueType = "SINGLE_SELECT"`
- `const ContactCreateResponseFieldValueTypeSocialHandle ContactCreateResponseFieldValueType = "SOCIAL_HANDLE"`
- `const ContactCreateResponseFieldValueTypeTelephone ContactCreateResponseFieldValueType = "TELEPHONE"`
- `const ContactCreateResponseFieldValueTypeText ContactCreateResponseFieldValueType = "TEXT"`
- `const ContactCreateResponseFieldValueTypeURL ContactCreateResponseFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactCreateResponseRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
### Contact Definitions Response
- `type ContactDefinitionsResponse struct{…}`
- `FieldDefinitions map[string, ContactDefinitionsResponseFieldDefinition]`
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 ContactDefinitionsResponseFieldDefinitionTypeConfiguration`
Type-specific configuration (e.g. select options, currency code).
- `Currency string`
ISO 4217 3-letter currency code.
- `HandleService string`
Social platform associated with this handle field.
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceTwitter ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "TWITTER"`
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceLinkedin ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "LINKEDIN"`
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceFacebook ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "FACEBOOK"`
- `const ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleServiceInstagram ContactDefinitionsResponseFieldDefinitionTypeConfigurationHandleService = "INSTAGRAM"`
- `MultipleValues bool`
Whether this field accepts multiple values.
- `Options []ContactDefinitionsResponseFieldDefinitionTypeConfigurationOption`
Available options for select fields.
- `ID string`
Unique identifier of the select option.
- `Label string`
Human-readable display name of the option.
- `Description string`
Description of the option, or null.
- `Unique bool`
Whether values for this field must be unique.
- `ValueType string`
Data type of the field.
- `const ContactDefinitionsResponseFieldDefinitionValueTypeAddress ContactDefinitionsResponseFieldDefinitionValueType = "ADDRESS"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeCheckbox ContactDefinitionsResponseFieldDefinitionValueType = "CHECKBOX"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeCurrency ContactDefinitionsResponseFieldDefinitionValueType = "CURRENCY"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeDatetime ContactDefinitionsResponseFieldDefinitionValueType = "DATETIME"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeEmail ContactDefinitionsResponseFieldDefinitionValueType = "EMAIL"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeFullName ContactDefinitionsResponseFieldDefinitionValueType = "FULL_NAME"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeMarkdown ContactDefinitionsResponseFieldDefinitionValueType = "MARKDOWN"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeMultiSelect ContactDefinitionsResponseFieldDefinitionValueType = "MULTI_SELECT"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeNumber ContactDefinitionsResponseFieldDefinitionValueType = "NUMBER"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeSingleSelect ContactDefinitionsResponseFieldDefinitionValueType = "SINGLE_SELECT"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeSocialHandle ContactDefinitionsResponseFieldDefinitionValueType = "SOCIAL_HANDLE"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeTelephone ContactDefinitionsResponseFieldDefinitionValueType = "TELEPHONE"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeText ContactDefinitionsResponseFieldDefinitionValueType = "TEXT"`
- `const ContactDefinitionsResponseFieldDefinitionValueTypeURL ContactDefinitionsResponseFieldDefinitionValueType = "URL"`
- `ID string`
Unique identifier of the field definition.
- `ReadOnly bool`
`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[string, ContactDefinitionsResponseRelationshipDefinition]`
Map of relationship keys to their definitions.
- `Cardinality string`
Whether this is a `has_one` or `has_many` relationship.
- `const ContactDefinitionsResponseRelationshipDefinitionCardinalityHasOne ContactDefinitionsResponseRelationshipDefinitionCardinality = "HAS_ONE"`
- `const ContactDefinitionsResponseRelationshipDefinitionCardinalityHasMany ContactDefinitionsResponseRelationshipDefinitionCardinality = "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 string`
Unique identifier of the relationship definition.
### Contact List Response
- `type ContactListResponse struct{…}`
- `Data []ContactListResponseData`
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[string, ContactListResponseDataField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactListResponseDataFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactListResponseDataFieldValueArray []string`
- `type ContactListResponseDataFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactListResponseDataFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactListResponseDataFieldValueTypeAddress ContactListResponseDataFieldValueType = "ADDRESS"`
- `const ContactListResponseDataFieldValueTypeCheckbox ContactListResponseDataFieldValueType = "CHECKBOX"`
- `const ContactListResponseDataFieldValueTypeCurrency ContactListResponseDataFieldValueType = "CURRENCY"`
- `const ContactListResponseDataFieldValueTypeDatetime ContactListResponseDataFieldValueType = "DATETIME"`
- `const ContactListResponseDataFieldValueTypeEmail ContactListResponseDataFieldValueType = "EMAIL"`
- `const ContactListResponseDataFieldValueTypeFullName ContactListResponseDataFieldValueType = "FULL_NAME"`
- `const ContactListResponseDataFieldValueTypeMarkdown ContactListResponseDataFieldValueType = "MARKDOWN"`
- `const ContactListResponseDataFieldValueTypeMultiSelect ContactListResponseDataFieldValueType = "MULTI_SELECT"`
- `const ContactListResponseDataFieldValueTypeNumber ContactListResponseDataFieldValueType = "NUMBER"`
- `const ContactListResponseDataFieldValueTypeSingleSelect ContactListResponseDataFieldValueType = "SINGLE_SELECT"`
- `const ContactListResponseDataFieldValueTypeSocialHandle ContactListResponseDataFieldValueType = "SOCIAL_HANDLE"`
- `const ContactListResponseDataFieldValueTypeTelephone ContactListResponseDataFieldValueType = "TELEPHONE"`
- `const ContactListResponseDataFieldValueTypeText ContactListResponseDataFieldValueType = "TEXT"`
- `const ContactListResponseDataFieldValueTypeURL ContactListResponseDataFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactListResponseDataRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
- `Object string`
The object type, always `"list"`.
- `TotalCount int64`
Total number of entities matching the query.
### Contact Retrieve Response
- `type ContactRetrieveResponse struct{…}`
- `ID string`
Unique identifier for the entity.
- `CreatedAt string`
ISO 8601 timestamp of when the entity was created.
- `Fields map[string, ContactRetrieveResponseField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactRetrieveResponseFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactRetrieveResponseFieldValueArray []string`
- `type ContactRetrieveResponseFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactRetrieveResponseFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactRetrieveResponseFieldValueTypeAddress ContactRetrieveResponseFieldValueType = "ADDRESS"`
- `const ContactRetrieveResponseFieldValueTypeCheckbox ContactRetrieveResponseFieldValueType = "CHECKBOX"`
- `const ContactRetrieveResponseFieldValueTypeCurrency ContactRetrieveResponseFieldValueType = "CURRENCY"`
- `const ContactRetrieveResponseFieldValueTypeDatetime ContactRetrieveResponseFieldValueType = "DATETIME"`
- `const ContactRetrieveResponseFieldValueTypeEmail ContactRetrieveResponseFieldValueType = "EMAIL"`
- `const ContactRetrieveResponseFieldValueTypeFullName ContactRetrieveResponseFieldValueType = "FULL_NAME"`
- `const ContactRetrieveResponseFieldValueTypeMarkdown ContactRetrieveResponseFieldValueType = "MARKDOWN"`
- `const ContactRetrieveResponseFieldValueTypeMultiSelect ContactRetrieveResponseFieldValueType = "MULTI_SELECT"`
- `const ContactRetrieveResponseFieldValueTypeNumber ContactRetrieveResponseFieldValueType = "NUMBER"`
- `const ContactRetrieveResponseFieldValueTypeSingleSelect ContactRetrieveResponseFieldValueType = "SINGLE_SELECT"`
- `const ContactRetrieveResponseFieldValueTypeSocialHandle ContactRetrieveResponseFieldValueType = "SOCIAL_HANDLE"`
- `const ContactRetrieveResponseFieldValueTypeTelephone ContactRetrieveResponseFieldValueType = "TELEPHONE"`
- `const ContactRetrieveResponseFieldValueTypeText ContactRetrieveResponseFieldValueType = "TEXT"`
- `const ContactRetrieveResponseFieldValueTypeURL ContactRetrieveResponseFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactRetrieveResponseRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.
### Contact Update Response
- `type ContactUpdateResponse struct{…}`
- `ID string`
Unique identifier for the entity.
- `CreatedAt string`
ISO 8601 timestamp of when the entity was created.
- `Fields map[string, ContactUpdateResponseField]`
Map of field names to their typed values. System fields are prefixed with `$` (e.g. `$name`, `$email`); custom attributes use their bare slug.
- `Value ContactUpdateResponseFieldValueUnion`
The field value, or null if unset.
- `string`
- `float64`
- `bool`
- `type ContactUpdateResponseFieldValueArray []string`
- `type ContactUpdateResponseFieldValueAddress struct{…}`
- `City string`
City name.
- `Country string`
2-letter ISO 3166-1 alpha-2 country code.
- `Latitude float64`
Latitude coordinate.
- `Longitude float64`
Longitude coordinate.
- `PostalCode string`
Postal or ZIP code.
- `State string`
State or province.
- `Street string`
Street address line 1.
- `Street2 string`
Street address line 2.
- `type ContactUpdateResponseFieldValueFullName struct{…}`
- `FirstName string`
The contact's first name.
- `LastName string`
The contact's last name.
- `ValueType string`
The data type of the field.
- `const ContactUpdateResponseFieldValueTypeAddress ContactUpdateResponseFieldValueType = "ADDRESS"`
- `const ContactUpdateResponseFieldValueTypeCheckbox ContactUpdateResponseFieldValueType = "CHECKBOX"`
- `const ContactUpdateResponseFieldValueTypeCurrency ContactUpdateResponseFieldValueType = "CURRENCY"`
- `const ContactUpdateResponseFieldValueTypeDatetime ContactUpdateResponseFieldValueType = "DATETIME"`
- `const ContactUpdateResponseFieldValueTypeEmail ContactUpdateResponseFieldValueType = "EMAIL"`
- `const ContactUpdateResponseFieldValueTypeFullName ContactUpdateResponseFieldValueType = "FULL_NAME"`
- `const ContactUpdateResponseFieldValueTypeMarkdown ContactUpdateResponseFieldValueType = "MARKDOWN"`
- `const ContactUpdateResponseFieldValueTypeMultiSelect ContactUpdateResponseFieldValueType = "MULTI_SELECT"`
- `const ContactUpdateResponseFieldValueTypeNumber ContactUpdateResponseFieldValueType = "NUMBER"`
- `const ContactUpdateResponseFieldValueTypeSingleSelect ContactUpdateResponseFieldValueType = "SINGLE_SELECT"`
- `const ContactUpdateResponseFieldValueTypeSocialHandle ContactUpdateResponseFieldValueType = "SOCIAL_HANDLE"`
- `const ContactUpdateResponseFieldValueTypeTelephone ContactUpdateResponseFieldValueType = "TELEPHONE"`
- `const ContactUpdateResponseFieldValueTypeText ContactUpdateResponseFieldValueType = "TEXT"`
- `const ContactUpdateResponseFieldValueTypeURL ContactUpdateResponseFieldValueType = "URL"`
- `HTTPLink string`
URL to view the entity in the Lightfield web app, or null.
- `Relationships map[string, ContactUpdateResponseRelationship]`
Map of relationship names to their associated entities. System relationships are prefixed with `$` (e.g. `$owner`, `$contact`).
- `Cardinality string`
Whether the relationship is `has_one` or `has_many`.
- `ObjectType string`
The type of the related object (e.g. `account`, `contact`).
- `Values []string`
IDs of the related entities.
- `UpdatedAt string`
ISO 8601 timestamp of when the entity was last updated, or null.
- `ExternalID string`
External identifier for the entity, or null if unset.