Integrations

Integrations and brand configuration.

Queries

currentIntegration

The current associated Integration for the API key

Returns: Integration! — An external data source connected to Endear

integration

A single Integration by ID

Arguments

  • id (ID!) — The unique identifier of the Integration

Returns: Integration — An external data source connected to Endear

integrations

Lists Integrations

Arguments

  • after (String) — A cursor to search after (only include first & after or last & before)
  • before (String) — A cursor to search before (only include first & after or last & before)
  • first (Int) — The number of results to fetch when searching forward (only include first & after or last & before)
  • includeDisabled (Boolean) — Whether or not to include disabled Integrations
  • includeDisconnected (Boolean) — Whether or not to include disconnected Integrations
  • last (Int) — The number of results to fetch when searching backward (only include first & after or last & before)
  • search (String) — A search query to filter results
  • sortBy (SortIntegrationsBy) — The sort key
  • sortDir (SortDirection) — The sort direction
  • type (IntegrationType) — The type of Integration to filter results by

Returns: IntegrationConnection! — A connection to a list of items.

integrationsByIds

A list of Integrations by IDs

Arguments

  • ids ([ID!]!) — The IDs of the Integrations

Returns: [Integration]! — An external data source connected to Endear

searchIntegrations

🚧

Deprecated: Use Query.integrations instead

Lists Integrations

Arguments

  • after (String) — A cursor to search after (only include first & after or last & before)
  • before (String) — A cursor to search before (only include first & after or last & before)
  • first (Int) — The number of results to fetch when searching forward (only include first & after or last & before)
  • includeDisabled (Boolean) — Whether or not to include disabled Integrations
  • includeDisconnected (Boolean) — Whether or not to include disconnected Integrations
  • last (Int) — The number of results to fetch when searching backward (only include first & after or last & before)
  • search (String) — A search query to filter results
  • sortBy (SortIntegrationsBy) — The sort key
  • sortDir (SortDirection) — The sort direction
  • type (IntegrationType) — The type of Integration to filter results by

Returns: IntegrationConnection! — A connection to a list of items.

Mutations

bulkUpsertExternalCustomers

Upserts one or more ExternalCustomers by ID

Arguments

Returns: OperationStatus!

bulkUpsertExternalLocations

Upserts one or more ExternalLocations by ID

Arguments

Returns: OperationStatus!

bulkUpsertExternalMarketingEvents

Upserts one or more ExternalMarketingEvents

Arguments

Returns: OperationStatus!

bulkUpsertExternalMarketingSubscriptions

Upserts one or more ExternalMarketingSubscriptions

Arguments

Returns: OperationStatus!

bulkUpsertExternalOrderItems

Upserts one or more ExternalOrderItems by ID

Arguments

Returns: OperationStatus!

bulkUpsertExternalOrders

Upserts one or more ExternalOrders by ID

Arguments

Returns: OperationStatus!

bulkUpsertExternalProducts

Upserts one or more ExternalProducts by ID

Arguments

Returns: OperationStatus!

bulkUpsertExternalProductVariants

Upserts one or more ExternalProductVariants by ID

Arguments

Returns: OperationStatus!

bulkUpsertExternalRefunds

Upserts one or more ExternalRefunds by ID

Arguments

Returns: OperationStatus!

requestIntegrationDataDeletion

Requests the deletion of all data for an Integration

Arguments

  • integrationId (ID!) — The ID of the Integration to delete data for

Returns: RequestIntegrationDataDeletionPayload!

revokeApiKey

Revokes an ApiKey

Arguments

  • id (ID!) — The ID of the ApiKey to revoke

Returns: ApiKey!

triggerIntegrationWorkflow

Triggers a workflow for an Integration

Arguments

  • validate (Boolean) — Whether to validate the Workflow input (once you have validated your workflow input, we recommend leaving this off to increase your throughput)
  • workflowId (ID!) — The unique identifier of the Workflow
  • workflowInput (JSONObject!) — The input for the Workflow

Returns: TriggerIntegrationWorkflowPayload!

updateApiKey

Updates an ApiKey

Arguments

  • id (ID!) — The ID of the ApiKey to update
  • label (NonEmptyString) — The new label for the ApiKey

Returns: ApiKey!

Objects

ApiKey

Fields

Integration

An external data source connected to Endear

Fields

  • created_at (DateTime!) — The date the Integration was created
  • disabled_at (DateTime) — The date the Integration was disabled due to connection issues
  • disconnected_at (DateTime) — The date the Integration was permanently disconnected
  • external_id (ID) — The external identifier of the Integration
  • id (ID!) — The unique identifier of the Integration
  • is_current (Boolean!) — If the Integration is the current Integration for the API key
  • label (String!) — The user-facing type & name label of the Integration
  • name (String!) — The user-facing name of the Integration
  • origin_website_url (String) — The origin website URL of the Integration
  • type (IntegrationType!) — The type of the Integration
  • updated_at (DateTime!) — The date the Integration was last updated
  • use_case (IntegrationUseCase) — The use-case of the Integration — 🚧 Deprecated: No longer used

IntegrationConnection

A connection to a list of items.

Fields

IntegrationDataDeletion

A request to delete an Integration's data

Fields

  • created_at (DateTime!) — The date and time the IntegrationDataDeletion was created
  • id (ID!) — The ID of the IntegrationDataDeletion
  • integration (Integration!) — The Integration for which data is being deleted
  • requested_by_integration (Integration)
  • requested_by_user (User)
  • updated_at (DateTime!) — The date and time the IntegrationDataDeletion was last updated

IntegrationEdge

An edge in a connection.

Fields

  • cursor (String!) — A cursor for use in pagination
  • node (Integration) — The item at the end of the edge

RequestIntegrationDataDeletionError

Fields

RequestIntegrationDataDeletionFailure

Fields

RequestIntegrationDataDeletionSuccess

Fields

TriggerIntegrationWorkflowError

Fields

TriggerIntegrationWorkflowFailure

Fields

TriggerIntegrationWorkflowSuccess

Fields

Interfaces

ApiKeyInterface

Fields

Implemented by

Unions

RequestIntegrationDataDeletionPayload

Possible types

TriggerIntegrationWorkflowPayload

Possible types

Enums

ApiKeyScope

The available scopes for an ApiKey

Values

  • read_all_customers
  • read_all_messages
  • read_all_notes
  • read_all_orders
  • read_all_tasks
  • read_appointments
  • read_current_brand
  • read_current_integration
  • read_customer_fields
  • read_customer_pii
  • read_customers
  • read_integrations
  • read_message_contents
  • read_messages
  • read_notes
  • read_orders
  • read_products
  • read_stories
  • read_tasks
  • read_teams
  • read_templates
  • read_users
  • send_drafts
  • trigger_integration_workflows
  • write_api_key
  • write_appointments
  • write_customer_fields
  • write_customers
  • write_drafts
  • write_external_customers
  • write_external_locations
  • write_external_orders
  • write_external_products
  • write_external_users
  • write_import_jobs
  • write_notes
  • write_stories
  • write_tasks
  • write_users

IntegrationType

The datasource type of an Integration

Values

  • API
  • ATTENTIVE
  • ENDEAR
  • GLADLY
  • GORGIAS
  • HEARTLAND
  • ITERABLE
  • KLAVIYO
  • KUSTOMER
  • KWI
  • LIGHTSPEED
  • NEW_STORE
  • OMETRIA
  • SHOPIFY
  • SQUARE
  • TEAMWORK
  • VEND
  • ZENDESK

IntegrationUseCase

A specific use case for the Integration (only applies to API Integrations)

Values

  • CSV
  • OTHER
  • ZAPIER

RequestIntegrationDataDeletionErrorCode

Values

  • FORBIDDEN — You do not have permission to perform this action
  • INTEGRATION_DATA_DELETION_ALREADY_REQUESTED — An integration data deletion has already been requested for this integration within the last 24 hours
  • INTEGRATION_NOT_DISCONNECTED — The integration must be disconnected before data deletion can be requested
  • INTEGRATION_NOT_FOUND — The integration was not found

SortIntegrationsBy

The available keys to sort Integrations

Values

  • CREATED_AT
  • UPDATED_AT

TriggerIntegrationWorkflowErrorCode

Values

  • WORKFLOW_NOT_FOUND — The workflow was not found