affinity.json•8.94 kB
{
"nodeType": "n8n-nodes-base.affinity",
"displayName": "Affinity",
"description": "Consume Affinity API",
"version": 1,
"properties": [
{
"name": "listId",
"displayName": "List ID",
"type": "string",
"default": "",
"description": "The unique ID of the list object to be retrieved",
"required": true,
"displayOptions": {
"show": {
"resource": [
"list"
],
"operation": [
"get"
]
}
}
},
{
"name": "returnAll",
"displayName": "Return All",
"type": "boolean",
"default": false,
"description": "Whether to return all results or only up to a given limit",
"displayOptions": {
"show": {
"resource": [
"list"
],
"operation": [
"getAll"
]
}
}
},
{
"name": "limit",
"displayName": "Limit",
"type": "number",
"default": 5,
"description": "Max number of results to return",
"typeOptions": {
"minValue": 1,
"maxValue": 10
},
"displayOptions": {
"show": {
"resource": [
"list"
],
"operation": [
"getAll"
],
"returnAll": [
false
]
}
}
},
{
"name": "operation",
"displayName": "Operation",
"type": "options",
"default": "get",
"description": "Get a list",
"options": [
{
"name": "Get",
"value": "get",
"description": "Get a list"
},
{
"name": "Get Many",
"value": "getAll",
"description": "Get many lists"
}
],
"displayOptions": {
"show": {
"resource": [
"list"
]
}
}
},
{
"name": "entityId",
"displayName": "Entity ID",
"type": "string",
"default": "",
"description": "The unique ID of the entity (person, organization, or opportunity) to add to this list",
"required": true,
"displayOptions": {
"show": {
"resource": [
"listEntry"
],
"operation": [
"create"
]
}
}
},
{
"name": "additionalFields",
"displayName": "Additional Fields",
"type": "collection",
"default": {},
"description": "The ID of a Person resource who should be recorded as adding the entry to the list. Must be a person who can access Affinity. If not provided the creator defaults to the owner of the API key.",
"placeholder": "Add Field",
"options": [
{
"name": "creator_id",
"displayName": "Creator ID",
"type": "string",
"default": "",
"description": "The ID of a Person resource who should be recorded as adding the entry to the list. Must be a person who can access Affinity. If not provided the creator defaults to the owner of the API key."
}
],
"displayOptions": {
"show": {
"resource": [
"listEntry"
],
"operation": [
"create"
]
}
}
},
{
"name": "listEntryId",
"displayName": "List Entry ID",
"type": "string",
"default": "",
"description": "The unique ID of the list entry object to be retrieved",
"required": true,
"displayOptions": {
"show": {
"resource": [
"listEntry"
],
"operation": [
"get"
]
}
}
},
{
"name": "name",
"displayName": "Name",
"type": "string",
"default": "",
"description": "The name of the organization",
"required": true,
"displayOptions": {
"show": {
"resource": [
"organization"
],
"operation": [
"create"
]
}
}
},
{
"name": "domain",
"displayName": "Domain",
"type": "string",
"default": "",
"description": "The domain name of the organization",
"required": true,
"displayOptions": {
"show": {
"resource": [
"organization"
],
"operation": [
"create"
]
}
}
},
{
"name": "organizationId",
"displayName": "Organization ID",
"type": "string",
"default": "",
"description": "Unique identifier for the organization",
"required": true,
"displayOptions": {
"show": {
"resource": [
"organization"
],
"operation": [
"update"
]
}
}
},
{
"name": "updateFields",
"displayName": "Update Fields",
"type": "collection",
"default": {},
"description": "The domain name of the organization",
"placeholder": "Add Field",
"options": [
{
"name": "domain",
"displayName": "Domain",
"type": "string",
"default": "",
"description": "The domain name of the organization"
},
{
"name": "name",
"displayName": "Name",
"type": "string",
"default": "",
"description": "The name of the organization"
}
],
"displayOptions": {
"show": {
"resource": [
"organization"
],
"operation": [
"update"
]
}
}
},
{
"name": "options",
"displayName": "Options",
"type": "collection",
"default": {},
"description": "Whether interaction dates will be present on the returned resources",
"placeholder": "Add option",
"options": [
{
"name": "withInteractionDates",
"displayName": "With Interaction Dates",
"type": "boolean",
"default": false,
"description": "Whether interaction dates will be present on the returned resources"
}
],
"displayOptions": {
"show": {
"resource": [
"organization"
],
"operation": [
"get"
]
}
}
},
{
"name": "firstName",
"displayName": "First Name",
"type": "string",
"default": "",
"description": "The first name of the person",
"required": true,
"displayOptions": {
"show": {
"resource": [
"person"
],
"operation": [
"create"
]
}
}
},
{
"name": "lastName",
"displayName": "Last Name",
"type": "string",
"default": "",
"description": "The last name of the person",
"required": true,
"displayOptions": {
"show": {
"resource": [
"person"
],
"operation": [
"create"
]
}
}
},
{
"name": "emails",
"displayName": "Emails",
"type": "string",
"default": [],
"description": "The email addresses of the person",
"placeholder": "info@example.com",
"typeOptions": {
"multipleValues": true
},
"displayOptions": {
"show": {
"resource": [
"person"
],
"operation": [
"create"
]
}
}
},
{
"name": "personId",
"displayName": "Person ID",
"type": "string",
"default": "",
"description": "Unique identifier for the person",
"required": true,
"displayOptions": {
"show": {
"resource": [
"person"
],
"operation": [
"update"
]
}
}
},
{
"name": "resource",
"displayName": "Resource",
"type": "options",
"default": "organization",
"options": [
{
"name": "List",
"value": "list"
},
{
"name": "List Entry",
"value": "listEntry"
},
{
"name": "Organization",
"value": "organization"
},
{
"name": "Person",
"value": "person"
}
]
}
],
"credentialsConfig": [
{
"name": "affinityApi",
"required": true
},
{
"name": "resource",
"required": false
}
],
"io": {
"inputs": [
"Main"
],
"outputs": [
"Main"
],
"outputNames": [],
"hints": {}
},
"wiring": {
"role": "generic",
"requires": [],
"optional": [],
"consumedBy": [],
"consumes": [
"Main"
],
"produces": [
"Main"
]
}
}