> ## Documentation Index
> Fetch the complete documentation index at: https://www.ayrshare.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Webhook History

> Get webhook delivery history grouped by action

export const PlansAvailable = ({plans = [], maxPackRequired}) => {
  let displayPlans = plans;
  if (plans && plans.length === 1) {
    const lowerCasePlan = plans[0].toLowerCase();
    if (lowerCasePlan === "basic") {
      displayPlans = ["Basic", "Premium", "Business", "Enterprise"];
    } else if (lowerCasePlan === "business") {
      displayPlans = ["Business", "Enterprise"];
    } else if (lowerCasePlan === "premium") {
      displayPlans = ["Premium", "Business", "Enterprise"];
    }
  }
  return <Note>
Available on {displayPlans.length === 1 ? "the " : ""}
{displayPlans.join(", ").replace(/\b\w/g, l => l.toUpperCase())}{" "}
{displayPlans.length > 1 ? "plans" : "plan"}.

{maxPackRequired && <span onClick={() => window.open('https://www.ayrshare.com/docs/additional/maxpack', '_self')} className="flex items-center mt-2 cursor-pointer">
 <span className="px-1.5 py-0.5 rounded text-sm" style={{
    backgroundColor: '#C264B6',
    color: 'white',
    fontSize: '12px'
  }}>
   Max Pack required
 </span>
</span>}
</Note>;
};

export const HeaderAPI = ({noProfileKey, profileKeyRequired}) => <>
    <ParamField header="Authorization" type="string" required>
      <a href="/apis/overview#authorization">API Key</a> of the Primary Profile.
      <br />
      <br />
      Format: <code>Authorization: Bearer API_KEY</code>
    </ParamField>
    {!noProfileKey && (profileKeyRequired ? <ParamField header="Profile-Key" type="string" required>
          <a href="/apis/overview#profile-key-format">Profile Key</a> of a User Profile.
          <br />
          <br />
          Format: <code>Profile-Key: PROFILE_KEY</code>
        </ParamField> : <ParamField header="Profile-Key" type="string">
          <a href="/apis/overview#profile-key-format">Profile Key</a> of a User Profile.
          <br />
          <br />
          Format: <code>Profile-Key: PROFILE_KEY</code>
        </ParamField>)}
  </>;

<PlansAvailable plans={["premium"]} maxPackRequired={false} />

## Webhook History

Retrieve recent webhook delivery history grouped by action type.
The response object contains keys for each action (e.g., `social`, `scheduled`, `messages`, `feed`, `batch`, `accountActivity`), and each key maps to an array of events.

## Header Parameters

<HeaderAPI />

## Query Parameters

<ParamField query="action" type="string">
  The webhook action to return history for the last 6 months. If not provided, all actions will be returned.

  Available actions: `social`, `scheduled`, `messages`, `feed`, `batch`, `accountActivity`

  Note: The `accountActivity` action will no longer be available after March 31, 2026.
</ParamField>

<ResponseExample>
  ```json 200: Response theme={"system"}
  {
    "social": [
      {
        "action": "social",
        "created": "2025-09-05T23:13:08Z",
        "displayName": "ayrshare",
        "hookId": "6e4zPT9ozQpxD72WX78r",
        "platform": "snapchat",
        "refId": "9abf1426d6ce9122ef11c72bd62e59807c5cc083",
        "source": "user",
        "timeStamp": 1757166928,
        "title": "Primary Profile",
        "type": "link",
        "url": "https://us-central1-ayrshare.cloudfunctions.net/testFeed"
      },
      {
        "action": "social",
        "created": "2025-09-05T23:13:00Z",
        "displayName": "madworlds25",
        "hookId": "UWURsgBxTdRAMCZJV4Yp",
        "platform": "snapchat",
        "refId": "9abf1426d6ce9122ef11c72bd62e59807c5cc083",
        "source": "user",
        "timeStamp": 1757166928,
        "title": "Primary Profile",
        "type": "unlink",
        "url": "https://us-central1-ayrshare.cloudfunctions.net/testFeed"
      }
    ],
    "scheduled": [
      {
        "action": "scheduled",
        "created": "2025-09-06T17:02:08Z",
        "errors": [],
        "hookId": "AxGbVck3Y7hsOdbAqVp7",
        "id": "NAOWq7cQf1CsyT7vqTng",
        "idShare": "v_pub_url~v2.7547022225119938615",
        "isVideo": true,
        "mediaUrls": [
          "https://img.ayrshare.com/random/portrait8.mp4"
        ],
        "platform": "tiktok",
        "platforms": [
          "tiktok"
        ],
        "post": "Wise men talk because they have something to say; fools, because they have to say something. - Plato",
        "postIds": [
          {
            "status": "success",
            "idShare": "v_pub_url~v2.7547022225119938615",
            "id": "7547022158694731022",
            "isVideo": true,
            "platform": "tiktok",
            "postUrl": "https://www.tiktok.com/@helmar1066/video/7547022158694731022",
            "mediaUrls": [
              "https://img.ayrshare.com/random/portrait8.mp4"
            ]
          }
        ],
        "postUrl": "https://www.tiktok.com/@helmar1066/video/7547022158694731022",
        "refId": "9abf1426d6ce9122ef11c72bd62e59807c5cc083",
        "source": "user",
        "status": "success",
        "subAction": "tikTokPublished",
        "timeStamp": 1757180499,
        "title": "Primary Profile",
        "url": "https://us-central1-ayrshare.cloudfunctions.net/testFeed"
      },
      {
        "action": "scheduled",
        "created": "2025-09-05T11:26:07Z",
        "errors": [],
        "hookId": "D92f6fMh2FCxNps4S27O",
        "id": "2Is9BJkDdoBv01K4nZ2k",
        "idShare": "v_pub_url~v2.7546563700132497463",
        "isVideo": true,
        "mediaUrls": [
          "https://img.ayrshare.com/random/portrait6.mp4"
        ],
        "platform": "tiktok",
        "platforms": [
          "tiktok"
        ],
        "post": "Either write something worth reading or do something worth writing. - Benjamin Franklin",
        "postIds": [
          {
            "status": "success",
            "idShare": "v_pub_url~v2.7546563700132497463",
            "id": "7546564355161099533",
            "isVideo": true,
            "platform": "tiktok",
            "postUrl": "https://www.tiktok.com/@helmar1066/video/7546564355161099533",
            "mediaUrls": [
              "https://img.ayrshare.com/random/portrait6.mp4"
            ]
          }
        ],
        "postUrl": "https://www.tiktok.com/@helmar1066/video/7546564355161099533",
        "refId": "9abf1426d6ce9122ef11c72bd62e59807c5cc083",
        "source": "user",
        "status": "success",
        "subAction": "tikTokPublished",
        "timeStamp": 1757180499,
        "title": "Primary Profile",
        "url": "https://us-central1-ayrshare.cloudfunctions.net/testFeed"
      }
    ]
  }
  ```
</ResponseExample>
