descriptionSimple webmention endpoint
ownerVanitas Gloam
last changeSun, 28 Apr 2024 12:41:55 +0000 (14:41 +0200)
readme

webmnt

webmnt (all lowercase) is an easy to set up Webmention endpoint for your website to receive IndieWeb responses with.

It's very much a hacked together work in progress but can be used if you are fine with that.

Installation

To install this on your server, simply build the binary with go build and copy it somewhere on your server to start it as a service with your init system of choice.
Configuration is detailed in the next section.

Dependencies

For ease of use, all dependencies are vendored in the vendor folder.
The following dependencies are in use:

Configuration

webmnt takes the path to your config file as an argument.

./webmnt config.json

{
  "blogHost": "localhost",
  "outdir": "/tmp",
  "listenAddr": "127.0.0.1:8080",
  "maxLength": 200,
  "blockList": [
    "evil.example.com"
  ]
}

The options do the following:

Usage

The server offers the receiver endpoint under the path /webmention using the source and target values that make up a mention to validate the response using the following criteria:

After these steps of validation, the reply will be saved in a file in the folder set in outdir.
Alternatively: If source returns HTTP 410 Gone, the response will get deleted from its file if it exists.

The name of the file is made up of your domain name and the subpath of the target, with slashes and dots replaced by underscores.

If a mention is sent multiple times it will be saved once, or if changes are detected since the previous send it will get updated.

The format in which responses are saved is as JSON objects separated by newlines meant to be read and processed further by additional software.

License

webmnt's code is under the GNU Affero General Public License v3.0 license.

The vendored modules in the vendor directory are under their original licenses.

shortlog
2024-04-28  Vanitas GloamClose http body main
2024-04-26  Vanitas GloamAdd/Fix response types
2024-04-24  Vanitas GloamReadme and license
2024-04-24  Vanitas GloamMake MaxLength configurable
2024-04-24  Vanitas GloamEscape dots from subpaths as well.
2024-04-24  Vanitas GloamHide blocked status
2024-04-24  Vanitas GloamSimpler outfile
2024-04-23  Vanitas GloamAdd DEL/UPDATE plus validate target canonical url
2024-04-22  Vanitas GloamAdd likes
2024-04-21  Vanitas GloamFirst deployed version
2024-04-20  Vanitas GloamInitial commit
heads
2 weeks ago main