Skip to content
AdCrunch
Esc
↑↓navigate↵open⌘Jpreview
On this page

meta_list_pages

List the Facebook Pages that your Meta connection can advertise from.

Ask which Facebook Page an ad can speak from. The agent reads all the Pages of your Meta connection, so that you can choose one before it builds a creative.

Which Facebook Page can an ad on Northwind run from?

The agent calls meta_list_pages with the Northwind advertiser. A long list comes one part at a time. The agent reads each part. You see the name of each Page. Change what runs on Meta shows where this step comes in the job.

Reference

Available on: Meta

List the Facebook Pages this Meta connection can advertise from. Every ad creative must speak from one of these Pages, so call this before creating a creative and confirm the choice with the user. Returns { id, name } per Page. The list is scoped to the connection, not to the advertiser, so it is the same for every advertiser on one Meta account; Meta itself refuses a Page the advertiser may not use when the creative is created. An answer can hold no Page and still carry nextCursor. When no answer holds a Page, up to the answer with no nextCursor, no Page was shared when Meta was connected — reconnecting and granting a Page is what fixes it. The answer holds at most limit rows (default 100, maximum 500). When it carries nextCursor, more rows exist: call this tool again with the same arguments and cursor set to that value. When it carries no nextCursor, you have every row.

Input

Argument Type Required Description
advertiserId string yes Advertiser account ID (acc_<id>). Must belong to the active organization — find one with list_advertisers.
cursor string, at least 1 character no The nextCursor of the previous page. Omit it to get the first page. Send it with no change, and with the same filters as the request that answered it: a cursor from a different query gets a 400 invalid_cursor. Do not build or change a cursor.
limit integer, 1 to 500 no The greatest number of rows on the page, from 1 to 500. The default is 100. A greater value gets a 400, with error of invalid_request. Default: 100.

Output

A successful call returns this object in structuredContent.

Field Type Always present Description
nextCursor string no Send this value as cursor to get the next page. It is absent on the last page.
pages array of object yes The Facebook Pages that this Meta connection can advertise from, in the order of Meta. The list can be empty when nextCursor is present. Then more Pages can exist. When no answer holds a Page, up to the answer with no nextCursor, the person who connected Meta shared no Page.
pages[].id string yes The Meta id of the Page. Give it as pageId to meta_create_creative.
pages[].name string yes The name of the Page on Facebook.

Failure codes

A failed call has isError set, and structuredContent.error holds one of these codes. Errors describes the shape of a failed call.

  • not_found
  • provider_not_connected
  • provider_error
  • invalid_cursor
  • forbidden
  • invalid_request
  • internal_error

Scope

The token must hold observe:read. Auth & scopes lists each scope.

Annotations

A client reads these hints. A hint that the tool does not declare has the default value of the MCP specification.

  • Read-only. The tool changes nothing.
  • Open world. The tool reaches a system outside AdCrunch, such as an ad platform.

Example

The arguments:

{
  "advertiserId": "acc_1485443900032333",
  "limit": 2
}

The result, in structuredContent:

{
  "nextCursor": "eyJwIjp7ImFmdGVyIjoiUVZGSVVuQjRZMkYwWDJoUWJuTmZPV1JmWkEifSwicSI6IjE2amMyZmw5amljIn0",
  "pages": [
    {
      "id": "104857392018274",
      "name": "Northwind Outdoor"
    },
    {
      "id": "112233445566778",
      "name": "Northwind Outlet"
    }
  ]
}

Was this page helpful?