Magnet Customer icon

Magnet Customer

Consume Magnet Customer API

Overview

This node integrates with the Magnet Customer API to create a new deal record within the CRM system. It allows users to specify details about the deal such as its title, description, associated organization or contact, pipeline and stage placement, expected closing date, status, assigned staff member, monetary amount, and any custom fields.

Typical use cases include automating sales workflows by programmatically adding deals when certain triggers occur (e.g., form submissions, lead qualification), syncing deals from other systems, or bulk creating deals based on external data sources.

For example, a sales automation workflow could create a new deal linked to a specific organization and assign it to a sales representative, setting the deal's pipeline stage and expected close date automatically.

Properties

Name Meaning
Authentication Method of authentication to use: either "API Token" or "OAuth2".
Title The title of the deal to create. This is a required string that identifies the deal.
Description Optional textual description providing more details about the deal.
Associate With Specifies whether the deal should be linked to an "Organization" or a "Contact".
Organization ID The ID of the organization to associate the deal with. Required if "Associate With" is set to "Organization".
Contact ID The ID of the contact to associate the deal with. Required if "Associate With" is set to "Contact".
Pipeline Name or ID The pipeline in which the deal will be placed. If omitted, defaults to the first stage of the default pipeline. Options are loaded dynamically from available pipelines.
Stage Name or ID The stage within the selected pipeline where the deal will be placed. If omitted, defaults to the first stage of the default pipeline. Options are loaded dynamically based on the selected pipeline.
Expectation of Closing Date/time indicating when the deal is expected to close.
Status The current status of the deal. Possible values: "Open", "Won", "Lost", "Deleted". Defaults to "Open" if not specified.
User Name or ID The ID of the active user (staff) to whom the deal activity will be assigned. If omitted, the authorized user is assigned. Options are loaded dynamically from active staff members.
Amount Numeric value representing the monetary value of the deal. Defaults to 0 if not set.
Custom Fields Allows setting additional custom fields not predefined in the standard properties. Users can add multiple custom fields by specifying their field name or ID and corresponding value.
Source Hidden property set to "n8n" indicating the source of the contact/deal creation.

Output

The node outputs JSON data representing the newly created deal object as returned by the Magnet Customer API. This includes all standard deal properties such as IDs, titles, descriptions, associations, pipeline and stage info, status, assigned user, amount, and any custom fields set.

No binary data output is produced by this node.

Dependencies

  • Requires access to the Magnet Customer API.
  • Requires credentials for authentication, either via an API token or OAuth2.
  • The node dynamically loads options for pipelines, stages, staff members, and custom fields by making API requests to the Magnet Customer service.
  • Proper configuration of the API credentials in n8n is necessary for successful operation.

Troubleshooting

  • Missing Required Fields: Errors may occur if mandatory fields like "Title" or association IDs are missing. Ensure all required inputs are provided.
  • Invalid Association IDs: Providing invalid or non-existent organization or contact IDs will cause API errors. Verify IDs before use.
  • Pipeline/Stage Not Found: If the specified pipeline or stage ID does not exist or is inaccessible, the deal creation will fail. Use the dynamic dropdowns to select valid options.
  • Authentication Failures: Incorrect or expired API tokens or OAuth2 credentials will prevent API calls. Re-authenticate or update credentials as needed.
  • Custom Field Errors: When setting custom fields, ensure field names or IDs are correct and values conform to expected formats.
  • API Rate Limits: Excessive requests may trigger rate limiting; implement retries or delays if necessary.
  • To resolve errors, review the error messages returned in the node output and verify input parameters and credentials.

Links and References

Discussion