Set Up a New Child Business Manager

The 2-Tier Business Manager solution was originally designed so that each user access token could only create one child Business Manager. However, the user can now create multiple child Business Managers as long as a primary page is set on each child Business Manager.

Note: Depending on if appsecret_proof is enabled on your app's settings, appsecret_proof might be needed as a parameter to each call you make. Refer to Securing Graph API Requests doc for how to set this option and how to generate appsecret_proof.

Get Started

Before you start, we recommend that you review these requirements and information:

App Permissions

  • business_management
  • ads_management

IDs

  • PARENT_BM_ID: ID of the Business Manager of the partner who owns the app.
  • CHILD_BM_ID: ID of the Business Manager that the Parent BM creates for the client.

Access Tokens

  • USER_Personal_Access_Token: The access token of the person providing the credentials to create the Child BM.
    • This token is generated using Facebook Login.
    • The partner should request global business_management scopes on the user's businesses and Pages rather than granular scopes.
    • This person should have Admin privileges on the Page being shared into the Child BM.
    • If the Page is owned by another BM, this person should have Admin privileges on the BM that owns the Page.
    • This token is used to authorize the Child BM creation and to share the Page into the Child BM for advertising.
  • PARENT_BM_ADMIN_SYSTEM_USER_ACCESS_TOKEN: The access token of the Admin System User in the Parent Business Manager.
    • This token is used to create and manage Child BMs.
  • CHILD_BM_SYSTEM_USER_ACCESS_TOKEN: The access token of the Admin System User created in the Child BM.
    • This token is used to create and manage Campaigns and other activity in the Child BM.

Create a Child Business Manager

Using the USER_Personal_Access_Token, create a Child Business Manager.

Example — Returns a Child Business Manager ID

curl \
  -F 'id=<Parent_Business_Manager_ID>' \
  -F 'name=Advertisers child BM (recommend naming similar to page)' \
  -F 'vertical=OTHER' \ // Specify the Business vertical
  -F 'shared_page_id=<PAGE_ID_FROM_USER>' \  //Optional parameter but needed if you want to publish ads promoting this page
                                             //Note: the user must be an admin of the BM that owns this page if this page is owned
  -F 'page_permitted_tasks=["ADVERTISE", "ANALYZE"]' \
  -F 'timezone_id=1' \
  -F 'access_token=<USER_Personal_Access_Token>' \
  -F 'appsecret_proof=<APP_SECRET_PROOF>' \  // Optional, depending on your app's security settings
  https://graph.facebook.com/<API_VERSION>/<PARENT_BM_Id>/owned_businesses

Response:

{
    “ID” : “12312812123132”  //store this child business manager ID and associate to user
}

Creating Multiple Child Business Managers per User

If the user wants to create multiple Child Business Managers using the same user credentials, the primary_page must be set on existing Child Business Managers created for that user. Make another POST call to set the primary_page of the existing Child Business Manager:

curl \
  -F 'primary_page=<PAGE_ID>' \
  -F 'access_token=<USER_Personal_Access_Token>' \
  -F 'appsecret_proof=<APP_SECRET_PROOF>' \  // Optional, depending on your app's security settings
  https://graph.facebook.com/<API_VERSION>/<BM_ID>

When creating another child Business Manager:

  • All of the existing Child Business Managers need to have a unique primary_page.
  • The shared_page_id must be set on the new Child Business Manager.
  • If the shared_page_id is used to create a new Child Business Manager, it cannot be a primary_page on any of the existing Child Business Managers.

Set Up Payment Method

To pay for the Child BM's advertisements, you will need to share your line of credit with each Child BM.


Step 1. Open a line of credit. Contact your Facebook representative and open a LOC within that Business Manager if does not already exist. The line of credit will display as a payment method in your Parent Business Manager.

Step 2. Accept Line of Credit Legal Terms.

  1. Open Business Manager > Business Settings > Payment Methods.
  2. Click Credit Settings and click on Legal Terms. Accept the legal terms.

Step 3. Fetch the line of credit ID and share with child Business Manager

  1. Go to your Parent Business Manager and Business Settings > Payment Methods. click on the Payment method. Store the PARENT_BM_Line_Of_Credit_ID from the URL. The URL looks something like this:
    https://business.facebook.com/settings/payment-methods/<PARENT_BM_Line_Of_Credit_ID>?business_id=<BUSINESS_ID>
  2. Use this Parent Business Manager line of credit ID in the API call below to share the line of credit ID from the Parent to the Child Business Manager. The amount is optional.
    curl \
      -F 'receiving_business_id=<CHILD_BUSINESS_MANAGER_ID>' \
      -F 'amount=<OPTIONAL_PARAMETER>' \  
      -F 'access_token=<Parent_BM_Admin_System_User_Access_Token>' \
      -F 'appsecret_proof=<APP_SECRET_PROOF>' \  // Optional, depending on your app's security settings
      https://graph.facebook.com/<API_VERSION>/<PARENT_BM_Line_Of_Credit_ID>/owning_credit_allocation_configs

If you don't specify an amount, your line of credit is equally divided among your Child Business Managers.

If you specify an amount only, that portion of your line of credit is assigned to the Child Business Manager.


Get the Child System User Token

Under the Child Business Manager, use this API call to create a system user and fetch the access token. This token is used for all subsequent calls to the Child Business Manager for creating or managing ads for this user.

curl \
  -F 'id=<CHILD_BUSINESS_MANAGER>' \
  -F 'app_id=<App_ID>' \
  -F 'scope=ads_management,business_management' \
  -F 'access_token=<Parent BM Admin System User Access Token>' \
  -F 'appsecret_proof=<APP_SECRET>' \
  https://graph.facebook.com/<API_VERSION>/<CHILD_BUSINESS_MANAGER_ID>/access_token

Fetch the System User's ID

Once you get the access token, you can use it to figure out the app scoped user ID. This is important to keep for storage later on.

curl -G \
  -d 'access_token=<Child BM System User Access Token>' \
  -d 'appsecret_proof=<APP_SECRET_PROOF>' \  // Optional, depending on your app's security settings
  https://graph.facebook.com/<API_VERSION>/<CHILD_BM_ID>/system_users

Get the Funding Source ID (LOC)

  1. Fetch the new funding source in the Child Business Manager. For this example, use this funding source later when creating an ad account.
  2. curl -G \
      -d 'fields=id,max_balance' \
      -d 'access_token=<Child BM Admin System User Access Token>' \
      -d 'appsecret_proof=<APP_SECRET_PROOF>' \   // Optional, depending on your app's security settings
      https://graph.facebook.com/<API_VERSION>/<CHILD_BUSINESS_MANAGER_ID>/extendedcredits
    Alternatively, you can fetch the funding source by going to your Child Business Manager and selecting Payments > click Credit Line Payment method. This populates the URL with a payment parameter as follows:
    payment-methods/<CHILD_PAYMENT_METHOD_ID>?business_id=
  3. Store this payment method ID for later use.

Create a New Ad Account with the Default Funding Source

Use the payment method ID from the Child Business Manager as the funding_id parameter.

funding_id cannot be updated after the ad account has been created.

curl \
  -F 'name=Advertisers Ad Account' \
  -F 'currency=USD' \
  -F 'timezone_id=1' \
  -F 'end_advertiser=<PAGE_ID>' \
  -F 'media_agency=NONE' \
  -F 'partner=NONE' \
  -F 'funding_id=<PAYMENT_METHOD_ID(from above)>' \
  -F 'access_token=<Child BM Admin System User Access Token>' \
  -F 'appsecret_proof=<APP_SECRET_PROOF>' \  // Optional, depending on your app's security settings
  https://graph.facebook.com/<API_VERSION>/CHILD_BM_ID/adaccount

Add the System User as an Admin to the New Ad Account

Add the system user as an admin to the new ad account under the Child Business Manager:

curl \
  -F 'user=<SYSTEM_USER_ID(from above)>' \
  -F 'tasks=MANAGE,ADVERTISE,ANALYZE' \
  -F 'business=<CHILD_BM_ID>' \
  -F 'access_token=<Child BM Admin System User Access Token>' \
  -F 'appsecret_proof=<APP_SECRET_PROOF>' \   // Optional, depending on your app's security settings
  https://graph.facebook.com/<API_VERSION>/<act_ACCOUNT_ID>/assigned_users

Congratulations! This is the final step in setting up a Child Business Manager to create and manage your client's campaigns.

Find Child Business Managers

To find all Child Business Manager IDs, run the following command to filter by client’s app scoped user ID:

curl -i -X GET \
  -F 'access_token=<PARENT_BM_ADMIN_SYSTEM_USER_ACCESS_TOKEN>' \
  -F 'appsecret_proof=<APP_SECRET_PROOF>' \  // Optional, depending on your app's security settings
"https://graph.facebook.com/<API_VERSION>/<parent_bm_id>/owned_businesses?client_user_id=<Client’s app scoped user ID>

Find the App scoped user ID with /me?fields=ids_for_apps (client user access token).

Next Steps

The next topics include additional features/actions you can use to augment your Business Manager experience.

Also, refer to asset sharing guides for accessing client assets into child BMs: