Facebook Pixel tracker

Brand2Social API Documentation

Comprehensive guide to Brand2Social API endpoints

Add Webhook Callback URL

Add or update a webhook callback URL for the organization to receive notifications. Specify the callback_url to handle events (e.g.,comments,likes,message). Requires ORG_ADMIN permission. If a callback URL exists for the organization, it will be updated; otherwise, a new one is created.

  • Method: POST
  • Endpoint: /api/api-services/v1/brand-service/add-webhook-callback-url
  • Returns: Confirmation of successful webhook callback URL addition or update

Add Webhook Callback URL

POST https://app.brand2social.com/api/api-services/v1/brand-service/add-webhook-callback-url

FieldTypeRequiredDescription
Authorizationstring (header)YesBearer token for authentication (requires ORG_ADMIN permission)
callback_urlstringYesThe URL to receive webhook notifications (e.g., https://your-service.com/webhook)
    
    
curl --location 'https://app.brand2social.com/api/api-services/v1/brand-service/add-webhook-callback-url' \
  --header 'Authorization: Bearer B2S_dummyToken' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "callback_url": "https://your-service.com/webhook"
}'
    
  

Response

{
  "status": "SUCCESS",
  "http_code": 200,
  "message": "Webhook callback url added/updated successfully",
  "data": ""
}

Error Response

{
  "status": "FAILURE",
  "http_code": 400,
  "message": "callback_url is required",
  "data": ""
}