Zapier

🚀 Using MarketingBlocks API with Zapier

✅ Step 1: Get Your Bearer Token


✅ Step 2: Configure Zapier

  1. Create a new Zap.

  2. Select your Trigger (e.g., Google Sheets, Webhook, Schedule).

  3. For the Action, choose:

    • Webhooks by Zapier → Custom Request

  4. Configure the request:

    • Method: POST / GET / etc. (depending on the endpoint)

    • URL: Example endpoints:

      • https://app.marketingblocks.ai/api/v1/social-sparks/create-post

      • https://app.marketingblocks.ai/api/v1/social-sparks/get-channels

    • Headers:

      {
        "Authorization": "Bearer mab_xxxxxxxxxxxxxxx",
        "Content-Type": "application/json"
      }
    • Body (for POST requests):

      • Select Raw JSON

      • Add required parameters based on the endpoint


✅ Step 3: Test the Connection

  • Click Test Action.

  • If everything is correct, you’ll receive a JSON response from the API.


✅ Example: Fetching Channels

  • Method: GET

  • URL:

    https://app.marketingblocks.ai/api/v1/social-sparks/get-channels
  • Headers:

    {
      "Authorization": "Bearer mab_abc123xyz456...",
      "Content-Type": "application/json"
    }
  • Success Response:

    {
      "channels": {
        "current_page": 1,
        "data": [
          {
            "channel_id": 254,
            "platform": "facebook",
            "account_name": "Jon Snow",
            "avatar": "https://example.com/avatar.jpg"
          }
        ],
        "total": 1
      },
      "status": true
    }

✅ Rate Limiting Notice

  • The API is rate-limited to 100 requests per second per token.

  • Avoid loops or large parallel runs that exceed this limit.

Last updated