Returns json data about a link shorted and a mesage.

  • URL
    https://short.admicro.vn/api/url-update

  • Method:
    POST

  • Header Params
    Required: token=[string]

  • Data Params
    Required: { alias = [string], new_long_url = [string] }

  • Success Response:

    • Content: { short : "//short.admicro.vn/alias-of-link", msg : "success" }

  • Error Response:

    • Content: { error : "Token is invalid" } ||

  { msg : "access denied" } || 

  { msg : "url exists" } ||

  { msg : "alias not found" } ||

  { msg : "parameters invalid" }
 

Sample Call:

$.ajax({

    url: "https://short.admicro.vn/api/url-update",

    headers: {"token": "1ee8be85a91e3600816fad0a38401cc"},

    dataType: "json",

    data: {"alias": "X3sW8Dk","new_long_url" : "https://genk.vn"},

    type : "POST",

    success : function(r) {

      console.log(r);

    }

});