POST
/
hook
/
webhook
curl --request POST \
  --url https://api.ayrshare.com/api/hook/webhook \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "action": "<string>",
  "url": "<string>",
  "secret": "<string>"
}'
{
  "status": "success",
  "action": "scheduled",
  "url": "https://mysite.com/hook",
  "refId": "3dc079614bdc3f281d9" // User Profile Ref Id
}
Available on Premium, Business, Enterprise plans.

Register Webhook

Register a new Webhook for one of the available actions. A Webhook may be registered with the Primary Profile or a User Profile.

Header Parameters

Authorization
string
required
API Key of the Primary Profile.

Format: Authorization: Bearer API_KEY
Profile-Key
string
Profile Key of a User Profile.

Format: Profile-Key: PROFILE_KEY

Body Parameters

action
string
required

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

url
string
required

The URL to be called on action. URL must be in a valid format and begin with https://

secret
string

Secret text used for HMAC. Please see overview for more details.

{
  "status": "success",
  "action": "scheduled",
  "url": "https://mysite.com/hook",
  "refId": "3dc079614bdc3f281d9" // User Profile Ref Id
}