Facebook Pages API Feed API

The Feed API from Facebook Pages API — 1 operation(s) for feed.

OpenAPI Specification

facebook-pages-feed-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Meta Graph API - Pages Comments Feed API
  description: 'Graph API endpoints for reading and managing Facebook Pages -

    publishing posts and photos, retrieving Page insights, moderating

    comments, configuring Page metadata, and subscribing to webhook

    events. Authentication uses a Page access token obtained via OAuth

    2.0 with scopes such as pages_manage_posts, pages_read_engagement,

    pages_manage_metadata, pages_messaging, and pages_show_list.

    '
  version: v22.0
  contact:
    name: Meta for Developers
    url: https://developers.facebook.com/docs/pages-api
servers:
- url: https://graph.facebook.com/v22.0
  description: Meta Graph API
security:
- PageAccessToken:
  - pages_show_list
  - pages_manage_posts
  - pages_read_engagement
  - pages_manage_metadata
tags:
- name: Feed
paths:
  /{page-id}/feed:
    parameters:
    - $ref: '#/components/parameters/PageId'
    get:
      summary: List Page feed posts
      operationId: listPageFeed
      parameters:
      - $ref: '#/components/parameters/Fields'
      - $ref: '#/components/parameters/Limit'
      responses:
        '200':
          description: Feed collection
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GraphCollection'
      tags:
      - Feed
    post:
      summary: Publish a post to the Page feed
      operationId: publishPost
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                message:
                  type: string
                link:
                  type: string
                  format: uri
                published:
                  type: boolean
                scheduled_publish_time:
                  type: integer
      responses:
        '200':
          description: Post created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
      tags:
      - Feed
components:
  schemas:
    GraphCollection:
      type: object
      properties:
        data:
          type: array
          items:
            type: object
        paging:
          type: object
          properties:
            cursors:
              type: object
              properties:
                before:
                  type: string
                after:
                  type: string
            next:
              type: string
            previous:
              type: string
  parameters:
    PageId:
      name: page-id
      in: path
      required: true
      schema:
        type: string
      description: Facebook Page ID
    Limit:
      name: limit
      in: query
      schema:
        type: integer
        default: 25
      description: Number of items per page.
    Fields:
      name: fields
      in: query
      schema:
        type: string
      description: Comma-separated list of fields to return.
  securitySchemes:
    PageAccessToken:
      type: oauth2
      description: 'OAuth 2.0 Page access token. Granted scopes determine which

        endpoints can be called. Send as a Bearer token or as the

        access_token query parameter.

        '
      flows:
        authorizationCode:
          authorizationUrl: https://www.facebook.com/v22.0/dialog/oauth
          tokenUrl: https://graph.facebook.com/v22.0/oauth/access_token
          scopes:
            pages_show_list: List Pages the user manages
            pages_manage_posts: Publish and edit posts
            pages_read_engagement: Read Page content and engagement
            pages_manage_metadata: Manage Page settings and subscribed apps
            pages_messaging: Send and receive Messenger messages
            pages_read_user_content: Read user-generated content on a Page
            pages_manage_engagement: Moderate comments and reactions