This function returns the MID of the Marketing Cloud account, based on the context of the authenticated user’s session. This is useful when creating customized pages for child Business Units (a feature available in earlier Enterprise 2.0 accounts).
NOTE: This function will only return the correct value in CloudPages when it is first assigned to a variable.
TIP: You can use the
memberidpersonalization string to display the related Business Unit MID of a published landing page or code resource.
This function does not accept any arguments.
The following example displays the Business Unit MID on a customized page, based on the context of the authenticated user.
%%[ var @MemberID set @MemberID = AuthenticatedMemberID() ]%% <p>This Business Unit MID is %%=v(@MemberID)=%%.</p>
The function returns the Business Unit MID based on the context of the authenticated user’s Marketing Cloud session.
<p>This Business Unit MID is 10987456.</p>