Back to Documentation
API Reference
11 min read

Webhooks

Receive real-time notifications in your application when events occur in MyFolioHub.

Webhooks allow your application to receive real-time notifications when specific events happen in your MyFolioHub account. Instead of polling our API for changes, MyFolioHub will "push" data to your server as soon as an event occurs, making your integrations faster and more efficient.

How Webhooks Work

A webhook is essentially a POST request sent from MyFolioHub to a URL you provide. The request body contains a JSON object with details about the event.

Supported Events

You can subscribe to a variety of events, including:

  • contact_form.submitted: Triggered when a visitor sends a message through your portfolio's contact form.
  • project.created: Triggered when a new project is added to your portfolio.
  • project.updated: Triggered when an existing project is modified.
  • portfolio.published: Triggered when you publish a new version of your portfolio.
  • domain.verified: Triggered when a custom domain is successfully connected.

Setting Up a Webhook

  1. Go to Settings > Developer Tools > Webhooks.
  2. Click "Add Endpoint".
  3. Enter the Payload URL where you want to receive the notifications.
  4. Select the Events you want to subscribe to.
  5. Click "Create Webhook".

Verifying Webhook Signatures

To ensure that a webhook request actually came from MyFolioHub and hasn't been tampered with, we include a signature in the X-MyFolioHub-Signature header. You should verify this signature using your Webhook Secret (found in the webhook settings).

Best Practices

Your webhook endpoint should return a 200 OK status code as quickly as possible. If your processing logic takes a long time, we recommend putting the event into a background queue and processing it asynchronously to avoid timeouts.

Retries and Failures

If your server returns an error (anything other than a 2xx status code), MyFolioHub will attempt to redeliver the webhook up to 5 times with exponential backoff. You can view the delivery history and retry specific events manually in your dashboard.

Was this article helpful?

Help us improve our documentation for everyone.

Share this guide

Help your colleagues learn too.

Still need help?

Our support team is here for you.

Contact Us
Webhooks | Documentation | MyFolioHub