{% extends "_root.html" %} {% block content %}

Received Webmentions

{% if webmentions %} {% for webmention in webmentions %} {% endfor %}
Timestamp Source Target Vouch Status
{{ webmention.timestamp }} {{ webmention.source }} {{ webmention.target }} {% if webmention.vouch %} {{ webmention.vouch }} {% else %} None {% endif %} {{ webmention.status }}
{% else %}

No webmentions received yet.

{% endif %}

Send a Test Webmention

Use curl to test the server:

From Approved Authority (will be accepted)

curl -X POST http://localhost:8080/webmention \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "source=https://aaronparecki.com/notes/2024/01/01/1&target=http://localhost:8080/post/1"

From Unapproved Authority (will return 449)

curl -X POST http://localhost:8080/webmention \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "source=https://unknown-site.com/post/1&target=http://localhost:8080/post/1"

From Unapproved Authority with Vouch (will be rejected in example)

curl -X POST http://localhost:8080/webmention \
  -H "Content-Type: application/x-www-form-urlencoded" \
  -d "source=https://unknown-site.com/post/1&target=http://localhost:8080/post/1&vouch=https://aaronparecki.com/notes/2024/01/01/1"

Note: This example server uses AlwaysAllow for domain approval, so all authorities are approved. In a real implementation, you would check against a list of approved domains.

{% endblock %}