Salesforce Marketing Cloud
Authentication: OAuth or server-to-server credentials. See Magic Link for the runtime auth flow, or Application credentials to bring your own OAuth app.
Sample use cases
- Find the contact record for
[email protected]and list the data extensions she appears in. - Upsert this week’s webinar registrants into the Webinar Attendees data extension.
- Run the Nightly Lead Sync automation and confirm it completed.
Available Tools
Check whether an email address is valid before sending: syntax, whether the domain accepts mail (MX), and known-bad a…
List Content Builder assets (emails, content blocks, images, templates) with an optional simple $filter (e.g. “assetT…
Search Content Builder assets with an advanced query: nested AND/OR operand trees, multiple sort clauses, and a field…
Get one Content Builder asset by ID, including its full content, views, data, and meta. Use list_assets or search_ass…
Create a Content Builder asset. Requires name and asset_type (e.g. htmlemail=208, htmlblock=197, png=28). Emails take…
Update a Content Builder asset (partial PATCH): name, description, folder, content, views, data, meta, channels, or a…
Delete a Content Builder asset by ID. Use list_assets or search_assets to find the asset ID.
List Content Builder categories (folders) with optional filter(e.g.′parentIdeq516016′),orderBy, and scope (‘Sh…
Create a Content Builder folder under a parent folder. Requires name and parent_id; call list_asset_categories first …
Rename or move a Content Builder folder (full PUT: name and parent_id are both required). Use list_asset_categories t…
Delete a Content Builder folder by ID. The folder must be empty: move or delete its assets and subfolders first. Use …
List Automation Studio automations with page-number pagination (page_size up to 500), optionally sorted (order_by) an…
Get one automation by ID, including its schedule, status, and steps with their activities. Use list_automations to fi…
Run an automation once now, performing all of its activities (queries, imports, sends). Use list_automations to find …
List Marketing Cloud folders of one type, e.g. category_type ‘dataextension’. Call this to get the category_id that c…
List Marketing Cloud campaigns with optional $orderBy (e.g. ‘createdDate DESC’). Returns campaign IDs for get_campaig…
Get one campaign by ID. Use list_campaigns to find campaign IDs.
Create a campaign. Requires name; optional description, campaign_code, color (hex without ’#’), and favorite. Returns…
Update a campaign’s name, description, campaign_code, color, or favorite flag. Provide at least one field; fields you…
Delete a campaign by ID. Use list_campaigns to find the campaign ID.
List the assets (emails, journeys, …) associated with a campaign. Each item’s id is the association ID remove_cam…
Associate one or more items with a campaign, e.g. asset_type ‘EMAIL’ with item_ids from list_assets. Use list_campaig…
Remove an asset association from a campaign. campaign_asset_id is the association id from list_campaign_assets (or …
Find contacts by email address (1-100 addresses). Returns the contact keys that use each address, for update_contact,…
Create a contact with attribute values grouped by attribute set (most accounts require the ‘Email Addresses’ set). Ca…
Update an existing contact’s attribute values, grouped by attribute set. Use search_contacts_by_email to find the con…
Delete contacts by contact key. Asynchronous: SFMC deletes them after the account’s retention period. Returns operati…
Get the status of a contact delete operation started by delete_contacts. Pass the operation_id that delete_contacts r…
List Contact Builder attribute set definitions and their attributes, with page-number pagination. Call this before cr…
Read rows from a data extension by external key or ID (exactly one), with page-number pagination (page_size up to 250…
Insert or update up to 500 rows synchronously, matched on primary key columns. Use list_data_extensions for the exter…
Queue a large batch of rows for a data extension asynchronously. mode ‘upsert’ (default) inserts or updates by primar…
Get the processing status of an asynchronous data request (requestStatus, resultStatus, hasErrors). The request_id co…
Get per-row results (status, errorCode, message) of a completed asynchronous data request, with page-number paginatio…
List data extensions with page-number pagination (page, page_size; use page_info.next_page). The API requires categor…
Get one data extension’s properties (name, key, folder, sendable settings, row count) by ID. Use list_data_extensions…
List a data extension’s fields (column names, types, lengths, primary keys, nullability). Call this before upserting …
Create a data extension with at least one field. Set is_sendable with sendable_custom_object_field and sendable_subsc…
Update a data extension’s name, description, sendable/testable flags, or retention settings. Pass at least one change…
Permanently delete a data extension and all its rows. Use list_data_extensions to find the ID. To remove only the row…
Add one or more fields (columns) to an existing data extension. The change is applied asynchronously, so re-check wit…
Change existing data extension fields (length, scale, nullability, default value), matched by name. Applied asynchron…
Delete ALL rows from a data extension, keeping its structure. This removes every row and cannot be undone. Use this t…
List Journey Builder event definitions (entry sources) with their id and eventDefinitionKey, optionally filtered by n…
Get one event definition by event_definition_id or key (exactly one). Use list_event_definitions to find them.
Create a journey entry event (e.g. type ‘APIEvent’) bound to a data extension. Use list_data_extensions for data_exte…
Replace an event definition (full body: type, name, key, data extension). Call get_event_definition first and resend …
Delete an event definition. Journeys that use it as an entry source must be stopped or deleted first. Use list_event_…
List Journey Builder journeys (lean summaries: id, key, version, status). Filter by status, type, tag, version, or na…
Get a journey’s full definition (triggers, activities, goals, exits) by journey_id or key (exactly one). Use list_jou…
Create a journey from a Journey Spec (key, name, triggers, activities). An API entry trigger references an event defi…
Replace a draft journey version’s full Journey Spec. Requires journey_id, key, version, and name; call get_journey fi…
Delete a journey, or one version with version_number. Running journeys must be stopped first with stop_journey. Use l…
Start publishing (activating) a journey version asynchronously. Returns a status_id; poll get_journey_publish_status …
Check the progress of a publish_journey request by its status_id. Returns status plus any validation errors and warni…
Stop a running journey version; contacts exit and it cannot be restarted (inverse of publish_journey). Use list_journ…
Pause a running journey version (contacts hold in place). Set all_versions to pause every version. Undo with resume_j…
Resume a paused journey version (inverse of pause_journey). Set all_versions to resume every version. Use list_journe…
Get a journey’s audit log (who created, modified, published, unpublished, or deleted it), optionally filtered by acti…
Inject a contact into a published journey by firing its API entry event. Use list_event_definitions for event_definit…
Remove up to 50 contacts from journeys (inverse of fire_entry_event). Each entry needs a contact_key and the journey …
Check whether contacts removed with remove_contacts_from_journey have exited. Pass the same contact_key/definition_ke…
List which journeys (key and version) the given contacts are currently in, plus contact keys that were not found. Use…
List transactional email send definitions with page-number pagination (page_size up to 100, the API maximum). Support…
Get one transactional email send definition by its definition key, including its email asset, subscription settings, …
Create a transactional email send definition that links a Content Builder email to a subscriber list. Call list_asset…
Update a transactional email send definition: name, description, status (Active/Inactive), classification, email asse…
Delete a transactional email send definition by definition key. Messages can no longer be sent with it. To stop sendi…
Send a real transactional email to 1-500 recipients using an active send definition. Call list_email_send_definitions…
Get the send status of one transactional email message by message key (e.g. ‘TransactionalSendEvents.EmailSent’). Use…