redir

Redir APIs

All possible routers: /s, and /x. The /s is the most complicated router because we are limited to use these prefixes (for many reasons, e.g. deploy to an existing domain that served a lot different routers. The prefix is configurable).

Thus, all kinds of data, pages, static files are served under this router.

GET /s

The GET request query parameters of /s are listed as follows:

POST /s

The POST request body of /s is in the following format:

{
    "op": "create",
    "alias": "awesome-link",
    "data": {
        "alias": "awesome-link",
        "url": "https://github.com/changkun",
        "private": true,
        "valid_from": "2022-01-01T00:00:00+00:00"
    }
}

License

MIT © 2020-2021 Changkun Ou