The World's First Military Grade Link Shortener

because your links deserve the best protection…

The API always responds in well-formed JSON and uses status codes to efficiently communicate error reasons. Attempting to use an outdated version of the API will return status code 403.

To create a new link using the API, issue a POST request to https://shashort.15318.de/api/v1/create with text/plain content containing the only the shortee (your URL).

$ curl -X POST https://shashort.15318.de/api/v1/create/ -d "https://example.com"

In case of success, the API returns ok in the status field and a hash field that contains the resulting hash you need to append to https://shashort.15318.de/resolve/ to be redirected to the shortee.

In case of errors, the API returns error in the status field and communicates the type of error in the HTTP Status Code: 429 indicates a rate limit violation, 413 the shortee being too long to parse, 400 a general error while parsing the shortee, and 500 a general internal error.

To resolve a link using the API, issue a GET request to https://shashort.15318.de/api/v1/resolve?hash=[your_hash].

$ curl -X POST "https://shashort.15318.de/api/v1/resolve/?hash=g0f…991"

In case of success, the API returns ok in the status field and a url field that contains the URL the hash maps to.

In case of errors, the API returns error in the status field and communicates the type of error in the HTTP Status Code: 400 indicates that the hash didn't resolve, and 500 a general internal error.

« Return to main site