{ "openapi" : "3.0.1", "info" : { "title" : "Contacts", "description" : "", "version" : "v3", "x-hubspot-product-tier-requirements" : { "marketing" : "FREE", "sales" : "FREE", "service" : "FREE", "cms" : "FREE" }, "x-hubspot-documentation-banner" : "NONE", "x-hubspot-api-use-case" : "Retrieve a contact list by ID to bring that contact data into your external system.", "x-hubspot-related-documentation" : [ { "name" : "Contacts Overview", "url" : "https://hubspotqa.dev/guides/api/crm/objects/contacts" } ], "x-hubspot-introduction" : "Use the contact lists API to create and manage contact lists." }, "servers" : [ { "url" : "https://api.hubapiqa.com" } ], "tags" : [ { "name" : "Batch" }, { "name" : "Basic" }, { "name" : "Public_Object" }, { "name" : "Associations" }, { "name" : "GDPR" }, { "name" : "Search" } ], "paths" : { "/crm/v3/objects/contacts/batch/read" : { "post" : { "tags" : [ "Batch" ], "summary" : "Read a batch of contacts by internal ID, or unique property values", "operationId" : "post-/crm/v3/objects/contacts/batch/read", "parameters" : [ { "name" : "archived", "in" : "query", "description" : "Whether to return only results that have been archived.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "boolean", "default" : false } } ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchReadInputSimplePublicObjectId" } } }, "required" : true }, "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchResponseSimplePublicObject" } } } }, "207" : { "description" : "multiple statuses", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchResponseSimplePublicObjectWithErrors" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.read" ] }, { "private_apps" : [ "crm.objects.contacts.read" ] } ] } }, "/crm/v3/objects/contacts/{contactId}" : { "get" : { "tags" : [ "Basic" ], "summary" : "Read", "description" : "Read an Object identified by `{contactId}`. `{contactId}` refers to the internal object ID by default, or optionally any unique property value as specified by the `idProperty` query param. Control what is returned via the `properties` query param.", "operationId" : "get-/crm/v3/objects/contacts/{contactId}", "parameters" : [ { "name" : "contactId", "in" : "path", "required" : true, "style" : "simple", "explode" : false, "schema" : { "type" : "string" } }, { "name" : "properties", "in" : "query", "description" : "A comma separated list of the properties to be returned in the response. If any of the specified properties are not present on the requested object(s), they will be ignored.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "array", "items" : { "type" : "string" } } }, { "name" : "propertiesWithHistory", "in" : "query", "description" : "A comma separated list of the properties to be returned along with their history of previous values. If any of the specified properties are not present on the requested object(s), they will be ignored.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "array", "items" : { "type" : "string" } } }, { "name" : "associations", "in" : "query", "description" : "A comma separated list of object types to retrieve associated IDs for. If any of the specified associations do not exist, they will be ignored.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "array", "items" : { "type" : "string" } } }, { "name" : "archived", "in" : "query", "description" : "Whether to return only results that have been archived.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "boolean", "default" : false } }, { "name" : "idProperty", "in" : "query", "description" : "The name of a property whose values are unique for this object type", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "string" } } ], "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/SimplePublicObjectWithAssociations" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.read" ] }, { "private_apps" : [ "crm.objects.contacts.read" ] } ] }, "delete" : { "tags" : [ "Basic" ], "summary" : "Archive", "description" : "Move an Object identified by `{contactId}` to the recycling bin.", "operationId" : "delete-/crm/v3/objects/contacts/{contactId}", "parameters" : [ { "name" : "contactId", "in" : "path", "required" : true, "style" : "simple", "explode" : false, "schema" : { "type" : "string" } } ], "responses" : { "204" : { "description" : "No content", "content" : { } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] }, "patch" : { "tags" : [ "Basic" ], "summary" : "Update", "description" : "Perform a partial update of an Object identified by `{contactId}`. `{contactId}` refers to the internal object ID by default, or optionally any unique property value as specified by the `idProperty` query param. Provided property values will be overwritten. Read-only and non-existent properties will be ignored. Properties values can be cleared by passing an empty string.", "operationId" : "patch-/crm/v3/objects/contacts/{contactId}", "parameters" : [ { "name" : "contactId", "in" : "path", "required" : true, "style" : "simple", "explode" : false, "schema" : { "type" : "string" } }, { "name" : "idProperty", "in" : "query", "description" : "The name of a property whose values are unique for this object type", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "string" } } ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/SimplePublicObjectInput" } } }, "required" : true }, "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/SimplePublicObject" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts/merge" : { "post" : { "tags" : [ "Public_Object" ], "summary" : "Merge two contacts with same type", "operationId" : "post-/crm/v3/objects/contacts/merge", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/PublicMergeInput" } } }, "required" : true }, "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/SimplePublicObject" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts/batch/archive" : { "post" : { "tags" : [ "Batch" ], "summary" : "Archive a batch of contacts by ID", "operationId" : "post-/crm/v3/objects/contacts/batch/archive", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchInputSimplePublicObjectId" } } }, "required" : true }, "responses" : { "204" : { "description" : "No content", "content" : { } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts/batch/create" : { "post" : { "tags" : [ "Batch" ], "summary" : "Create a batch of contacts", "operationId" : "post-/crm/v3/objects/contacts/batch/create", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchInputSimplePublicObjectInputForCreate" } } }, "required" : true }, "responses" : { "201" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchResponseSimplePublicObject" } } } }, "207" : { "description" : "multiple statuses", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchResponseSimplePublicObjectWithErrors" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts/batch/update" : { "post" : { "tags" : [ "Batch" ], "summary" : "Update a batch of contacts", "operationId" : "post-/crm/v3/objects/contacts/batch/update", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchInputSimplePublicObjectBatchInput" } } }, "required" : true }, "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchResponseSimplePublicObject" } } } }, "207" : { "description" : "multiple statuses", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/BatchResponseSimplePublicObjectWithErrors" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts/gdpr-delete" : { "post" : { "tags" : [ "GDPR" ], "summary" : "GDPR DELETE", "description" : "Permanently delete a contact and all associated content to follow GDPR. Use optional property 'idProperty' set to 'email' to identify contact by email address. If email address is not found, the email address will be added to a blocklist and prevent it from being used in the future.", "operationId" : "post-/crm/v3/objects/contacts/gdpr-delete", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/PublicGdprDeleteInput" } } }, "required" : true }, "responses" : { "204" : { "description" : "No content", "content" : { } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts" : { "get" : { "tags" : [ "Basic" ], "summary" : "List", "description" : "Read a page of contacts. Control what is returned via the `properties` query param.", "operationId" : "get-/crm/v3/objects/contacts", "parameters" : [ { "name" : "limit", "in" : "query", "description" : "The maximum number of results to display per page.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "integer", "format" : "int32", "default" : 10 } }, { "name" : "after", "in" : "query", "description" : "The paging cursor token of the last successfully read resource will be returned as the `paging.next.after` JSON property of a paged response containing more results.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "string" } }, { "name" : "properties", "in" : "query", "description" : "A comma separated list of the properties to be returned in the response. If any of the specified properties are not present on the requested object(s), they will be ignored.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "array", "items" : { "type" : "string" } } }, { "name" : "propertiesWithHistory", "in" : "query", "description" : "A comma separated list of the properties to be returned along with their history of previous values. If any of the specified properties are not present on the requested object(s), they will be ignored. Usage of this parameter will reduce the maximum number of objects that can be read by a single request.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "array", "items" : { "type" : "string" } } }, { "name" : "associations", "in" : "query", "description" : "A comma separated list of object types to retrieve associated IDs for. If any of the specified associations do not exist, they will be ignored.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "array", "items" : { "type" : "string" } } }, { "name" : "archived", "in" : "query", "description" : "Whether to return only results that have been archived.", "required" : false, "style" : "form", "explode" : true, "schema" : { "type" : "boolean", "default" : false } } ], "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/CollectionResponseSimplePublicObjectWithAssociationsForwardPaging" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.read" ] }, { "private_apps" : [ "crm.objects.contacts.read" ] } ] }, "post" : { "tags" : [ "Basic" ], "summary" : "Create", "description" : "Create a contact with the given properties and return a copy of the object, including the ID. Documentation and examples for creating standard contacts is provided.", "operationId" : "post-/crm/v3/objects/contacts", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/SimplePublicObjectInputForCreate" } } }, "required" : true }, "responses" : { "201" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/SimplePublicObject" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.write" ] }, { "private_apps" : [ "crm.objects.contacts.write" ] } ] } }, "/crm/v3/objects/contacts/search" : { "post" : { "tags" : [ "Search" ], "operationId" : "post-/crm/v3/objects/contacts/search", "parameters" : [ ], "requestBody" : { "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/PublicObjectSearchRequest" } } }, "required" : true }, "responses" : { "200" : { "description" : "successful operation", "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/CollectionResponseWithTotalSimplePublicObjectForwardPaging" } } } }, "default" : { "$ref" : "#/components/responses/Error" } }, "security" : [ { "oauth2" : [ "crm.objects.contacts.read" ] }, { "private_apps" : [ "crm.objects.contacts.read" ] } ], "x-hubspot-rate-limit-exemptions" : [ "ten-secondly" ] } } }, "components" : { "schemas" : { "StandardError" : { "required" : [ "category", "context", "errors", "links", "message", "status" ], "type" : "object", "properties" : { "subCategory" : { "type" : "object", "properties" : { } }, "context" : { "type" : "object", "additionalProperties" : { "type" : "array", "items" : { "type" : "string" } } }, "links" : { "type" : "object", "additionalProperties" : { "type" : "string" } }, "id" : { "type" : "string" }, "category" : { "type" : "string" }, "message" : { "type" : "string" }, "errors" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/ErrorDetail" } }, "status" : { "type" : "string" } } }, "CollectionResponseAssociatedId" : { "required" : [ "results" ], "type" : "object", "properties" : { "paging" : { "$ref" : "#/components/schemas/Paging" }, "results" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/AssociatedId" } } } }, "PublicAssociationsForObject" : { "required" : [ "to", "types" ], "type" : "object", "properties" : { "types" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/AssociationSpec" } }, "to" : { "$ref" : "#/components/schemas/PublicObjectId" } } }, "BatchResponseSimplePublicObject" : { "required" : [ "completedAt", "results", "startedAt", "status" ], "type" : "object", "properties" : { "completedAt" : { "type" : "string", "format" : "date-time" }, "requestedAt" : { "type" : "string", "format" : "date-time" }, "startedAt" : { "type" : "string", "format" : "date-time" }, "links" : { "type" : "object", "additionalProperties" : { "type" : "string" } }, "results" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObject" } }, "status" : { "type" : "string", "enum" : [ "PENDING", "PROCESSING", "CANCELED", "COMPLETE" ] } } }, "FilterGroup" : { "required" : [ "filters" ], "type" : "object", "properties" : { "filters" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/Filter" } } } }, "ErrorDetail" : { "required" : [ "message" ], "type" : "object", "properties" : { "subCategory" : { "type" : "string", "description" : "A specific category that contains more specific detail about the error" }, "code" : { "type" : "string", "description" : "The status code associated with the error detail" }, "in" : { "type" : "string", "description" : "The name of the field or parameter in which the error was found." }, "context" : { "type" : "object", "additionalProperties" : { "type" : "array", "items" : { "type" : "string" } }, "description" : "Context about the error condition", "example" : { "missingScopes" : [ "scope1", "scope2" ] } }, "message" : { "type" : "string", "description" : "A human readable message describing the error along with remediation steps where appropriate" } } }, "ForwardPaging" : { "type" : "object", "properties" : { "next" : { "$ref" : "#/components/schemas/NextPage" } } }, "SimplePublicObjectId" : { "required" : [ "id" ], "type" : "object", "properties" : { "id" : { "type" : "string" } } }, "BatchReadInputSimplePublicObjectId" : { "required" : [ "inputs", "properties", "propertiesWithHistory" ], "type" : "object", "properties" : { "propertiesWithHistory" : { "type" : "array", "items" : { "type" : "string" } }, "idProperty" : { "type" : "string" }, "inputs" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObjectId" } }, "properties" : { "type" : "array", "items" : { "type" : "string" } } } }, "BatchInputSimplePublicObjectId" : { "required" : [ "inputs" ], "type" : "object", "properties" : { "inputs" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObjectId" } } } }, "ValueWithTimestamp" : { "required" : [ "sourceType", "timestamp", "value" ], "type" : "object", "properties" : { "sourceId" : { "type" : "string" }, "sourceType" : { "type" : "string" }, "sourceLabel" : { "type" : "string" }, "updatedByUserId" : { "type" : "integer", "format" : "int32" }, "value" : { "type" : "string" }, "timestamp" : { "type" : "string", "format" : "date-time" } } }, "CollectionResponseWithTotalSimplePublicObjectForwardPaging" : { "required" : [ "results", "total" ], "type" : "object", "properties" : { "total" : { "type" : "integer", "format" : "int32" }, "paging" : { "$ref" : "#/components/schemas/ForwardPaging" }, "results" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObject" } } } }, "SimplePublicObject" : { "required" : [ "createdAt", "id", "properties", "updatedAt" ], "type" : "object", "properties" : { "createdAt" : { "type" : "string", "format" : "date-time" }, "archived" : { "type" : "boolean", "example" : false }, "archivedAt" : { "type" : "string", "format" : "date-time" }, "propertiesWithHistory" : { "type" : "object", "additionalProperties" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/ValueWithTimestamp" } } }, "id" : { "type" : "string", "example" : "512" }, "properties" : { "type" : "object", "additionalProperties" : { "type" : "string", "nullable" : true }, "example" : { "property_date" : "1572480000000", "property_radio" : "option_1", "property_number" : "17", "property_string" : "value", "property_checkbox" : "false", "property_dropdown" : "choice_b", "property_multiple_checkboxes" : "chocolate;strawberry" } }, "updatedAt" : { "type" : "string", "format" : "date-time" } }, "example" : { "id" : "512", "properties" : { "company" : "Biglytics", "createdate" : "2019-10-30T03:30:17.883Z", "email" : "bcooper@biglytics.net", "firstname" : "Bryan", "lastmodifieddate" : "2019-12-07T16:50:06.678Z", "lastname" : "Cooper", "phone" : "(877) 929-0687", "website" : "biglytics.net" }, "createdAt" : "2019-10-30T03:30:17.883Z", "updatedAt" : "2019-12-07T16:50:06.678Z", "archived" : false } }, "PublicObjectId" : { "required" : [ "id" ], "type" : "object", "properties" : { "id" : { "type" : "string" } } }, "Paging" : { "type" : "object", "properties" : { "next" : { "$ref" : "#/components/schemas/NextPage" }, "prev" : { "$ref" : "#/components/schemas/PreviousPage" } } }, "PublicObjectSearchRequest" : { "required" : [ "after", "filterGroups", "limit", "properties", "sorts" ], "type" : "object", "properties" : { "query" : { "type" : "string" }, "limit" : { "type" : "integer", "format" : "int32" }, "after" : { "type" : "string" }, "sorts" : { "type" : "array", "items" : { "type" : "string" } }, "properties" : { "type" : "array", "items" : { "type" : "string" } }, "filterGroups" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/FilterGroup" } } } }, "Error" : { "required" : [ "category", "correlationId", "message" ], "type" : "object", "properties" : { "subCategory" : { "type" : "string", "description" : "A specific category that contains more specific detail about the error" }, "context" : { "type" : "object", "additionalProperties" : { "type" : "array", "items" : { "type" : "string" } }, "description" : "Context about the error condition", "example" : { "missingScopes" : [ "scope1", "scope2" ], "invalidPropertyName" : [ "propertyValue" ] } }, "correlationId" : { "type" : "string", "description" : "A unique identifier for the request. Include this value with any error reports or support tickets", "format" : "uuid", "example" : "aeb5f871-7f07-4993-9211-075dc63e7cbf" }, "links" : { "type" : "object", "additionalProperties" : { "type" : "string" }, "description" : "A map of link names to associated URIs containing documentation about the error or recommended remediation steps", "example" : { "knowledge-base" : "https://www.hubspot.com/products/service/knowledge-base" } }, "message" : { "type" : "string", "description" : "A human readable message describing the error along with remediation steps where appropriate", "example" : "Invalid input (details will vary based on the error)" }, "category" : { "type" : "string", "description" : "The error category", "example" : "VALIDATION_ERROR" }, "errors" : { "type" : "array", "description" : "further information about the error", "items" : { "$ref" : "#/components/schemas/ErrorDetail" } } }, "example" : { "message" : "Invalid input (details will vary based on the error)", "correlationId" : "aeb5f871-7f07-4993-9211-075dc63e7cbf", "category" : "VALIDATION_ERROR", "links" : { "knowledge-base" : "https://www.hubspot.com/products/service/knowledge-base" } } }, "BatchResponseSimplePublicObjectWithErrors" : { "required" : [ "completedAt", "results", "startedAt", "status" ], "type" : "object", "properties" : { "completedAt" : { "type" : "string", "format" : "date-time" }, "numErrors" : { "type" : "integer", "format" : "int32" }, "requestedAt" : { "type" : "string", "format" : "date-time" }, "startedAt" : { "type" : "string", "format" : "date-time" }, "links" : { "type" : "object", "additionalProperties" : { "type" : "string" } }, "results" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObject" } }, "errors" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/StandardError" } }, "status" : { "type" : "string", "enum" : [ "PENDING", "PROCESSING", "CANCELED", "COMPLETE" ] } } }, "PublicGdprDeleteInput" : { "required" : [ "objectId" ], "type" : "object", "properties" : { "idProperty" : { "type" : "string" }, "objectId" : { "type" : "string" } } }, "SimplePublicObjectInput" : { "required" : [ "properties" ], "type" : "object", "properties" : { "properties" : { "type" : "object", "additionalProperties" : { "type" : "string" }, "example" : { "property_date" : "1572480000000", "property_radio" : "option_1", "property_number" : "17", "property_string" : "value", "property_checkbox" : "false", "property_dropdown" : "choice_b", "property_multiple_checkboxes" : "chocolate;strawberry" } } }, "example" : { "properties" : { "email" : "bcooper@biglytics.net", "phone" : "(877) 929-0687", "company" : "Biglytics", "website" : "biglytics.net", "lastname" : "Cooper", "firstname" : "Bryan" }, "associations" : [ ] } }, "CollectionResponseSimplePublicObjectWithAssociationsForwardPaging" : { "required" : [ "results" ], "type" : "object", "properties" : { "paging" : { "$ref" : "#/components/schemas/ForwardPaging" }, "results" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObjectWithAssociations" } } } }, "AssociationSpec" : { "required" : [ "associationCategory", "associationTypeId" ], "type" : "object", "properties" : { "associationCategory" : { "type" : "string", "enum" : [ "HUBSPOT_DEFINED", "USER_DEFINED", "INTEGRATOR_DEFINED" ] }, "associationTypeId" : { "type" : "integer", "format" : "int32" } } }, "PublicMergeInput" : { "required" : [ "objectIdToMerge", "primaryObjectId" ], "type" : "object", "properties" : { "objectIdToMerge" : { "type" : "string" }, "primaryObjectId" : { "type" : "string" } } }, "SimplePublicObjectWithAssociations" : { "required" : [ "createdAt", "id", "properties", "updatedAt" ], "type" : "object", "properties" : { "associations" : { "type" : "object", "additionalProperties" : { "$ref" : "#/components/schemas/CollectionResponseAssociatedId" } }, "createdAt" : { "type" : "string", "format" : "date-time" }, "archived" : { "type" : "boolean" }, "archivedAt" : { "type" : "string", "format" : "date-time" }, "propertiesWithHistory" : { "type" : "object", "additionalProperties" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/ValueWithTimestamp" } } }, "id" : { "type" : "string" }, "properties" : { "type" : "object", "additionalProperties" : { "type" : "string", "nullable" : true } }, "updatedAt" : { "type" : "string", "format" : "date-time" } }, "example" : { "properties" : { "company" : "Biglytics", "createdate" : "2019-10-30T03:30:17.883Z", "email" : "bcooper@biglytics.net", "firstname" : "Bryan", "lastmodifieddate" : "2019-12-07T16:50:06.678Z", "lastname" : "Cooper", "phone" : "(877) 929-0687", "website" : "biglytics.net" } } }, "Filter" : { "required" : [ "operator", "propertyName" ], "type" : "object", "properties" : { "highValue" : { "type" : "string" }, "propertyName" : { "type" : "string" }, "values" : { "type" : "array", "items" : { "type" : "string" } }, "value" : { "type" : "string" }, "operator" : { "type" : "string", "description" : "null", "enum" : [ "EQ", "NEQ", "LT", "LTE", "GT", "GTE", "BETWEEN", "IN", "NOT_IN", "HAS_PROPERTY", "NOT_HAS_PROPERTY", "CONTAINS_TOKEN", "NOT_CONTAINS_TOKEN" ] } } }, "BatchInputSimplePublicObjectBatchInput" : { "required" : [ "inputs" ], "type" : "object", "properties" : { "inputs" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObjectBatchInput" } } } }, "BatchInputSimplePublicObjectInputForCreate" : { "required" : [ "inputs" ], "type" : "object", "properties" : { "inputs" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/SimplePublicObjectInputForCreate" } } } }, "PreviousPage" : { "required" : [ "before" ], "type" : "object", "properties" : { "before" : { "type" : "string" }, "link" : { "type" : "string" } } }, "SimplePublicObjectBatchInput" : { "required" : [ "id", "properties" ], "type" : "object", "properties" : { "id" : { "type" : "string" }, "properties" : { "type" : "object", "additionalProperties" : { "type" : "string" } } }, "example" : { "id" : "1", "properties" : { "email" : "bcooper@biglytics.net", "phone" : "(877) 929-0687", "company" : "Biglytics", "website" : "biglytics.net", "lastname" : "Cooper", "firstname" : "Bryan" } } }, "AssociatedId" : { "required" : [ "id", "type" ], "type" : "object", "properties" : { "id" : { "type" : "string" }, "type" : { "type" : "string" } } }, "NextPage" : { "required" : [ "after" ], "type" : "object", "properties" : { "link" : { "type" : "string", "example" : "?after=NTI1Cg%3D%3D" }, "after" : { "type" : "string", "example" : "NTI1Cg%3D%3D" } }, "example" : { "after" : "NTI1Cg%3D%3D", "link" : "?after=NTI1Cg%3D%3D" } }, "SimplePublicObjectInputForCreate" : { "required" : [ "associations", "properties" ], "type" : "object", "properties" : { "associations" : { "type" : "array", "items" : { "$ref" : "#/components/schemas/PublicAssociationsForObject" } }, "properties" : { "type" : "object", "additionalProperties" : { "type" : "string" } } }, "example" : { "properties" : { "email" : "bcooper@biglytics.net", "phone" : "(877) 929-0687", "company" : "Biglytics", "website" : "biglytics.net", "lastname" : "Cooper", "firstname" : "Bryan" }, "associations" : [ ] } } }, "responses" : { "Error" : { "description" : "An error occurred.", "content" : { "*/*" : { "schema" : { "$ref" : "#/components/schemas/Error" } } } } }, "securitySchemes" : { "oauth2_legacy" : { "type" : "oauth2", "flows" : { "authorizationCode" : { "authorizationUrl" : "https://app.hubspot.com/oauth/authorize", "tokenUrl" : "https://api.hubapi.com/oauth/v1/token", "scopes" : { "crm.objects.custom.write" : "Change custom object records", "crm.objects.goals.read" : "Read goals", "crm.objects.leads.write" : "Modify lead objects", "e-commerce" : "e-commerce", "tickets" : "Read and write tickets", "crm.objects.goals.write" : "Write goals", "crm.objects.leads.read" : "Read lead objects", "crm.objects.custom.read" : "View custom object records" } } } }, "oauth2" : { "type" : "oauth2", "flows" : { "authorizationCode" : { "authorizationUrl" : "https://app.hubspot.com/oauth/authorize", "tokenUrl" : "https://api.hubapi.com/oauth/v1/token", "scopes" : { "crm.objects.subscriptions.read" : "Read Commerce Subscriptions", "crm.objects.carts.read" : "Read carts", "crm.objects.line_items.write" : "Line Items", "crm.objects.deals.read" : " ", "crm.objects.commercepayments.read" : "Read the COMMERCE_PAYMENT object.", "crm.objects.contacts.write" : " ", "crm.objects.users.read" : "Read User CRM objects", "crm.objects.companies.read" : " ", "crm.objects.deals.write" : " ", "crm.objects.carts.write" : "Write cart", "crm.objects.users.write" : "Write User CRM objects", "crm.objects.orders.read" : "Read orders", "crm.objects.quotes.write" : "Quotes", "crm.objects.orders.write" : "Write orders", "crm.objects.invoices.read" : "Read invoices objects", "crm.objects.companies.write" : " ", "crm.objects.contacts.read" : " ", "crm.objects.quotes.read" : "Quotes", "crm.objects.line_items.read" : "Line Items" } } } }, "private_apps_legacy" : { "type" : "apiKey", "name" : "private-app-legacy", "in" : "header", "flows" : { "authorizationCode" : { "scopes" : { } } } }, "private_apps" : { "type" : "apiKey", "name" : "private-app", "in" : "header", "flows" : { "authorizationCode" : { "scopes" : { "crm.objects.contacts.read" : "", "crm.objects.contacts.write" : "" } } } } } }, "x-hubspot-available-client-libraries" : [ "PHP", "Node", "Ruby", "Python" ], "x-hubspot-product-tier-requirements" : { "marketing" : "FREE", "sales" : "FREE", "service" : "FREE", "cms" : "FREE" }, "x-hubspot-documentation-banner" : "NONE" }