When to use this endpoint

Use MarketingSource_getRequestedDetails for CRM2 record views, export enrichment, or a bounded batch of known source IDs. Use the compact list route for populating selectors.

Authentication and permissions

The request must authenticate with signed API-key fields or a logged-in CRM session. The handler requires login but performs no additional Marketing-page, create, edit, delete, or role-permission check.

All reads and writes use the authenticated tenant’s tables. CRM1 and CRM2 hide some controls through client-side permissions; these routes do not repeat those UI checks.

Parameters

ParameterTypeRequiredDescription
fieldsNative arrayNoMapped fields to return. Omission requests id, name, createDate, and lastEdited. Use a native array, not JSON text.
id or idsInteger-compatible or native arrayNoLimit results to row IDs. id wins when both are present.
nameString or native arrayNoCase-insensitive exact name match, or an exact-name IN list.
createDate, lastEditedInteger-compatible or native arrayNoExact stored Unix timestamps after integer conversion.
orderMapped field, field object, or native arrayNoOptional ordering; an object can use {"id":"name","dir":"desc"}.

Example request

$rows = FM_api('MarketingSource_getRequestedDetails', [
	'id' => ['30124'],
	'fields' => ['id', 'name', 'lastEdited'],
]);

Example response

[
  {"id":"30124","name":"Trade show","lastEdited":"2026-10-01 15:10:00"}
]

Errors and unusual responses

ResponseCondition
{"error":"not logged in"}No authenticated tenant context is available. Invalid signed credentials can be rejected by the dispatcher before the handler runs.
[]No source matches every supplied filter.
Runtime/type errorfields is supplied as JSON text or another scalar instead of a native array.

Legacy application errors may be returned with HTTP 200. Check the decoded response for error, not only the HTTP status.

Behaviour and edge cases

  • The table has no deleted or active state, so every matching stored row is eligible.
  • createDate and lastEdited are formatted SQL datetime strings converted from Unix timestamps.
  • Unknown requested fields are silently skipped; id is always added.
  • There is no pagination, default ordering, or implicit limit. Omitting filters returns every source.

See it in Fieldmotion

CRM1

No direct CRM1 caller was found; CRM1 uses MarketingSources_list, MarketingSources_getDT, and MarketingSources_getById.

CRM2

CRM2’s job export widget calls this route to resolve selected marketing-source IDs; the generic lead-source page also derives it for detail reads.

Related endpoints