openapi: 3.0.3 info: version: 0.25.7 title: Unified CRM Accounts Syncs API contact: name: Supaglue email: docs@supaglue.com url: https://supaglue.com description: '#### Introduction Welcome to the Unified API (CRM) documentation. You can use this API to write to multiple third-party providers within the CRM category. [View common schema for CRM](https://docs.supaglue.com/platform/common-schemas/crm) #### Base API URL ``` https://api.supaglue.io/crm/v2 ``` ' servers: - url: https://api.supaglue.io/crm/v2 description: Supaglue API tags: - name: Syncs description: A `Sync` is a way for a Customer to sync data from a Provider to a Destination on a schedule. paths: /syncs: get: operationId: getSyncs tags: - Syncs security: - x-api-key: [] summary: Get Syncs description: Get a list of Syncs. parameters: - name: cursor in: query schema: type: string example: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw description: The pagination cursor value - name: page_size in: query schema: type: string example: '100' description: Number of results to return per page - name: customer_id in: query schema: type: string example: my-customer-1 description: The customer ID that uniquely identifies the customer in your application - name: provider_name in: query schema: type: string example: salesforce description: The provider name - name: object_type in: query schema: type: string enum: - common - standard - custom example: standard description: The object type to filter by - name: object in: query schema: type: string example: contact description: The object to filter by - name: entity_id deprecated: true in: query schema: type: string example: e74b5a4f-f252-4a6c-940c-f35873498543 description: The entity id to filter by responses: '200': description: Sync content: application/json: schema: allOf: - $ref: '#/components/schemas/pagination' - type: object properties: results: type: array items: $ref: '#/components/schemas/sync_with_provider_and_customer' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '500': $ref: '#/components/responses/internalServerError' '501': $ref: '#/components/responses/notImplemented' /syncs/_pause: parameters: - $ref: '#/components/parameters/x-customer-id' - $ref: '#/components/parameters/x-provider-name' post: operationId: pauseSync summary: Pause sync tags: - Syncs security: - x-api-key: [] requestBody: required: true content: application/json: schema: oneOf: - type: object title: 'Data model: Objects' properties: object_type: type: string enum: - common - standard - custom example: standard description: The object type to filter by object: type: string example: Contact description: The Provider object to filter by (case sensitive) required: - object_type - object - type: object title: 'Data model: Common Schema' properties: object_type: type: string enum: - common example: common description: The object type to filter by object: type: string example: contact description: The Supaglue object to filter by required: - object_type - object - type: object title: 'Data model: Entities' deprecated: true properties: entity_id: type: string description: The entity id to filter by required: - entity_id responses: '200': description: Sync paused content: application/json: schema: $ref: '#/components/schemas/sync' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '422': $ref: '#/components/responses/unprocessableEntity' '500': $ref: '#/components/responses/internalServerError' '501': $ref: '#/components/responses/notImplemented' /syncs/_resume: parameters: - $ref: '#/components/parameters/x-customer-id' - $ref: '#/components/parameters/x-provider-name' post: operationId: resumeSync summary: Resume sync tags: - Syncs security: - x-api-key: [] requestBody: required: true content: application/json: schema: oneOf: - type: object title: 'Data model: Objects' properties: object_type: type: string enum: - common - standard - custom example: standard description: The object type to filter by object: type: string example: contact description: The object to filter by required: - object_type - object - type: object title: 'Data model: Entities' deprecated: true properties: entity_id: type: string example: cfba6060-c43a-4a63-8a8c-501c6099f8b0 description: The entity id to filter by required: - entity_id responses: '200': description: Sync resumed content: application/json: schema: $ref: '#/components/schemas/sync' example: id: 2caab904-3c7c-4894-8c82-4c28913b3419 type: entity entity_id: db602f88-7a8c-44f0-8932-c92f1e033494 connection_id: da732713-2ff7-4f3b-8728-257a026177cd sync_config_id: f2b3ea2a-6a1e-4983-91f1-92a4db4d7abd paused: false '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '422': $ref: '#/components/responses/unprocessableEntity' '500': $ref: '#/components/responses/internalServerError' '501': $ref: '#/components/responses/notImplemented' /syncs/_trigger: parameters: - $ref: '#/components/parameters/x-customer-id' - $ref: '#/components/parameters/x-provider-name' post: operationId: triggerSync summary: Trigger sync tags: - Syncs security: - x-api-key: [] requestBody: required: true content: application/json: schema: oneOf: - type: object title: 'Data model: Objects' properties: object_type: type: string enum: - standard - custom description: The object type to filter by example: standard object: type: string example: contact description: The Provider object to filter by (case sensitive) perform_full_refresh: type: boolean example: true required: - object_type - object - type: object title: 'Data model: Common Schema' properties: object_type: type: string enum: - common description: The object type to filter by example: common object: type: string example: contact description: The Supaglue object to filter by perform_full_refresh: type: boolean example: true required: - object_type - object - type: object title: 'Data model: Entities' deprecated: true properties: entity_id: type: string description: The entity id to filter by perform_full_refresh: type: boolean example: true required: - entity_id responses: '200': description: Sync triggered content: application/json: schema: $ref: '#/components/schemas/sync' '400': $ref: '#/components/responses/badRequest' '401': $ref: '#/components/responses/unauthorized' '403': $ref: '#/components/responses/forbidden' '404': $ref: '#/components/responses/notFound' '409': $ref: '#/components/responses/conflict' '422': $ref: '#/components/responses/unprocessableEntity' '500': $ref: '#/components/responses/internalServerError' '501': $ref: '#/components/responses/notImplemented' components: schemas: errors: type: array items: type: object properties: id: type: string description: A unique identifier for the instance of the error. Provide this to support when contacting Supaglue. example: 9366efb4-8fb1-4a28-bfb0-8d6f9cc6b5c5 detail: type: string description: A detailed description of the error. example: 'Property values were not valid: [{"isValid":false,"message":"Property \"__about_us\" does not exist","error":"PROPERTY_DOESNT_EXIST","name":"__about_us","localizedErrorMessage":"Property \"__about_us\" does not exist"}]' problem_type: type: string description: The Supaglue error code associated with the error. example: MISSING_REQUIRED_FIELD deprecated: true title: type: string description: A brief description of the error. The schema and type of message will vary by Provider. example: 'Property values were not valid ' code: type: string description: The Supaglue error code associated with the error. example: MISSING_REQUIRED_FIELD status: type: string description: The HTTP status code associated with the error. example: '400' meta: type: object description: Additional metadata about the error. properties: cause: type: object description: The cause of the error. Usually the underlying error from the remote Provider. example: code: 400 body: status: error message: 'Property values were not valid: [{"isValid":false,"message":"Property \"__about_us\" does not exist","error":"PROPERTY_DOESNT_EXIST","name":"__about_us","localizedErrorMessage":"Property \"__about_us\" does not exist"}]' correlationId: ac94252c-90b5-45d2-ad1d-9a9f7651d7d2 category: VALIDATION_ERROR headers: access-control-allow-credentials: 'false' cf-cache-status: DYNAMIC cf-ray: 8053d17b9dae9664-SJC connection: close content-length: '361' content-type: application/json;charset=utf-8 date: Mon, 11 Sep 2023 23:51:22 GMT nel: '{"success_fraction":0.01,"report_to":"cf-nel","max_age":604800}' report-to: '{"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v3?s=FgwuXObO%2Fz6ahUJKsxjDLaXTWjooJ8tB0w4%2B%2BKaulGStx0FGkn1PoJoOx2KrFMfihzNdfAqikq7CmgbdlmwKB8hkmp3eTb68qpg10LXFlRgiSqRhbWM7yYSfo8CXmPBc"}],"group":"cf-nel","max_age":604800}' server: cloudflare strict-transport-security: max-age=31536000; includeSubDomains; preload vary: origin, Accept-Encoding x-content-type-options: nosniff x-envoy-upstream-service-time: '91' x-evy-trace-listener: listener_https x-evy-trace-route-configuration: listener_https/all x-evy-trace-route-service-name: envoyset-translator x-evy-trace-served-by-pod: iad02/hubapi-td/envoy-proxy-6c94986c56-9xsh2 x-evy-trace-virtual-host: all x-hubspot-correlation-id: ac94252c-90b5-45d2-ad1d-9a9f7651d7d2 x-hubspot-ratelimit-interval-milliseconds: '10000' x-hubspot-ratelimit-max: '100' x-hubspot-ratelimit-remaining: '99' x-hubspot-ratelimit-secondly: '10' x-hubspot-ratelimit-secondly-remaining: '9' x-request-id: ac94252c-90b5-45d2-ad1d-9a9f7651d7d2 x-trace: 2B1B4386362759B6A4C34802AD168B803DDC1BE770000000000000000000 origin: type: string enum: - remote-provider - supaglue description: The origin of the error. example: remote-provider application_name: type: string description: The name of the application that generated the error. example: MyCompany Production required: - origin additionalProperties: true required: - id - detail - problem_type - title - code - status - meta example: - meta: cause: code: 400 body: status: error message: 'Property values were not valid: [{"isValid":false,"message":"Property \"__about_us\" does not exist","error":"PROPERTY_DOESNT_EXIST","name":"__about_us","localizedErrorMessage":"Property \"__about_us\" does not exist"}]' correlationId: ac94252c-90b5-45d2-ad1d-9a9f7651d7d2 category: VALIDATION_ERROR headers: access-control-allow-credentials: 'false' cf-cache-status: DYNAMIC cf-ray: 8053d17b9dae9664-SJC connection: close content-length: '361' content-type: application/json;charset=utf-8 date: Mon, 11 Sep 2023 23:51:22 GMT nel: '{"success_fraction":0.01,"report_to":"cf-nel","max_age":604800}' report-to: '{"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v3?s=FgwuXObO%2Fz6ahUJKsxjDLaXTWjooJ8tB0w4%2B%2BKaulGStx0FGkn1PoJoOx2KrFMfihzNdfAqikq7CmgbdlmwKB8hkmp3eTb68qpg10LXFlRgiSqRhbWM7yYSfo8CXmPBc"}],"group":"cf-nel","max_age":604800}' server: cloudflare strict-transport-security: max-age=31536000; includeSubDomains; preload vary: origin, Accept-Encoding x-content-type-options: nosniff x-envoy-upstream-service-time: '91' x-evy-trace-listener: listener_https x-evy-trace-route-configuration: listener_https/all x-evy-trace-route-service-name: envoyset-translator x-evy-trace-served-by-pod: iad02/hubapi-td/envoy-proxy-6c94986c56-9xsh2 x-evy-trace-virtual-host: all x-hubspot-correlation-id: ac94252c-90b5-45d2-ad1d-9a9f7651d7d2 x-hubspot-ratelimit-interval-milliseconds: '10000' x-hubspot-ratelimit-max: '100' x-hubspot-ratelimit-remaining: '99' x-hubspot-ratelimit-secondly: '10' x-hubspot-ratelimit-secondly-remaining: '9' x-request-id: ac94252c-90b5-45d2-ad1d-9a9f7651d7d2 x-trace: 2B1B4386362759B6A4C34802AD168B803DDC1BE770000000000000000000 detail: 'Property values were not valid: [{"isValid":false,"message":"Property \"__about_us\" does not exist","error":"PROPERTY_DOESNT_EXIST","name":"__about_us","localizedErrorMessage":"Property \"__about_us\" does not exist"}]' problem_type: MISSING_REQUIRED_FIELD title: 'Property values were not valid ' code: MISSING_REQUIRED_FIELD status: '400' id: 9366efb4-8fb1-4a28-bfb0-8d6f9cc6b5c5 pagination: type: object properties: next: type: string nullable: true example: eyJpZCI6IjQyNTc5ZjczLTg1MjQtNDU3MC05YjY3LWVjYmQ3MDJjNmIxNCIsInJldmVyc2UiOmZhbHNlfQ== previous: type: string nullable: true example: eyJpZCI6IjBjZDhmYmZkLWU5NmQtNDEwZC05ZjQxLWIwMjU1YjdmNGI4NyIsInJldmVyc2UiOnRydWV9 total_count: type: number example: 100 required: - next - previous sync: oneOf: - type: object title: 'Data model: Objects' properties: id: type: string example: 7026e4e8-15d7-48d8-b997-f2592b654619 type: type: string enum: - object example: object object_type: type: string enum: - common - standard - custom example: standard object: type: string example: contact description: The Provider's object name (case sensitive) connection_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e4 sync_config_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e5 paused: type: boolean example: false required: - id - type - object_type - object - connection_id - sync_config_id - paused - type: object title: 'Data model: Common Schema' properties: id: type: string example: 7026e4e8-15d7-48d8-b997-f2592b654619 type: type: string enum: - object example: object object_type: type: string enum: - common example: standard object: type: string example: contact description: Supaglue's object name connection_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e4 sync_config_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e5 paused: type: boolean example: false required: - id - type - object_type - object - connection_id - sync_config_id - paused - type: object title: 'Data model: Entities' deprecated: true properties: id: type: string example: 7026e4e8-15d7-48d8-b997-f2592b654619 type: type: string enum: - entity example: entity entity_id: type: string example: 94e6cb6c-0ec8-423f-8873-21054979a6b1 connection_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e4 sync_config_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e5 paused: type: boolean example: false required: - id - type - entity_id - connection_id - sync_config_id - paused sync_with_provider_and_customer: oneOf: - type: object title: 'Data model: Objects' properties: id: type: string example: 971cb76d-9558-42fe-8f3b-8a531c32bd5f type: type: string enum: - object example: object object_type: type: string enum: - common - standard - custom example: standard object: type: string example: contact connection_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e4 sync_config_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e5 paused: type: boolean example: false provider_name: type: string example: hubspot customer_id: type: string example: my-customer-1 required: - id - type - object_type - object - connection_id - sync_config_id - paused - provider_name - customer_id - type: object title: 'Data model: Entities' properties: id: type: string example: 971cb76d-9558-42fe-8f3b-8a531c32bd5f type: type: string enum: - entity example: entity entity_id: type: string example: 70da3830-b717-49cb-91f0-22fb3f09a97a connection_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e4 sync_config_id: type: string example: 3217ea51-11c8-43c9-9547-6f197e02e5e5 paused: type: boolean example: false provider_name: type: string example: hubspot customer_id: type: string example: my-customer-1 required: - id - type - entity_id - connection_id - sync_config_id - paused - provider_name - customer_id responses: conflict: description: Conflict content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' notFound: description: Not found content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' internalServerError: description: Internal server error content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' unauthorized: description: Unauthorized content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' notImplemented: description: Not implemented content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' forbidden: description: Forbidden content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' unprocessableEntity: description: Unprocessable entity content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' badRequest: description: Bad request content: application/json: schema: type: object properties: errors: $ref: '#/components/schemas/errors' parameters: x-customer-id: name: x-customer-id in: header schema: type: string example: my-customer-1 description: The customer ID that uniquely identifies the customer in your application required: true x-provider-name: name: x-provider-name in: header schema: type: string example: salesforce description: The provider name required: true securitySchemes: x-api-key: type: apiKey name: x-api-key in: header description: API key to allow developers to access the API