Scurteaza URL API

Prezentare Generală

Our API allows you to provide short url functionality to any of your existing websites. When you register for an account, you're generated a unique API key which should be used in the API calls listed below.

The examples below generate responses in json but you can also use xml by replacing the end of the url call with .xml.


Creeaza

Creați o nouă adresă URL scurta oferind o versiune base64 codificata de url-uri lungi originale.

Parametrii:
Nume: Type: Descriere:
key string Cheie de acces API. Login to view.
url string Base64 encoded version of your long url. base64_encode() in PHP.
Valori de returnare:
Nume: Type: Descriere:
url_id integer ID URL unic.
short_url string Short url including domain name.
short_url_part string Short url part. (excluding domain name)
original_url string The original decoded long url.
date_time string Date and time of the API call. In the format yyyy-mm-dd hh:mm:ss.
Exemplul de cerere:
API Address: http://11x.ro
GET //api/v1/7a89bcbdc39bd4e3ff9145050d67ae15/shorturl/create/url/BASE64_ENCODED_LONG_URL.json
Exemplul de răspuns:
{
   "code":200,
   "data":{
      "url_id":"1388597",
      "short_url":"http://11x.ro/srt",
      "short_url_part":"srt",
      "original_url":"http://www.bbc.co.uk",
      "date_time":"2013-04-04 16:18:05"
   }
}

Creeaza (Opțiuni Suplimentare)

Create a new short url including some additional settings such as a custom short url, password to access and an expiry date.

Parametrii:
Nume: Type: Descriere:
key string Cheie de acces API. Login to view.
url string Base64 encoded version of your long url. base64_encode() in PHP.
custom_url (optional) string Personalizare URL scurt
password (optional) string Parola pentru a accesa URL-ul.
expiry_date (optional) string Date to expire the url. In the format yyyy-mm-dd.
base_domain (optional) string Url to use for the short url. Must already exist on the site. No http or trailing forward slash. i.e. domain.com
Valori de returnare:
Nume: Type: Descriere:
url_id integer ID URL unic.
short_url string Short url including domain name.
short_url_part string Short url part. (excluding domain name)
original_url string The original decoded long url.
date_time string Date and time of the API call. In the format yyyy-mm-dd hh:mm:ss.
Exemplul de cerere:
API Address: http://11x.ro
GET //api/v1/7a89bcbdc39bd4e3ff9145050d67ae15/shorturl/create/custom_url/CUSTOM_SHORT_URL/password/PASSWORD_TO_ACCESS/expiry_date/URL_EXPIRY_DATE/url/BASE64_ENCODED_LONG_URL.json
Exemplul de răspuns:
{
   "code":200,
   "data":{
      "url_id":"1388598",
      "short_url":"http://11x.ro/bbc",
      "short_url_part":"bbc",
      "original_url":"http://www.bbc.co.uk",
      "date_time":"2013-04-04 16:18:08"
   }
}

Dezactivat

Disable an active short url within your account.

Parametrii:
Nume: Type: Descriere:
key string Cheie de acces API. Login to view.
short_url string Base64 encoded version of your short url. base64_encode() in PHP.
Valori de returnare:
Nume: Type: Descriere:
url_id integer ID URL unic.
status string Short url status.
short_url string Short url including domain name.
date_time string Date and time of the API call. In the format yyyy-mm-dd hh:mm:ss.
Exemplul de cerere:
API Address: http://11x.ro
GET //api/v1/7a89bcbdc39bd4e3ff9145050d67ae15/shorturl/disable/short_url/BASE64_ENCODED_SHORT_URL.json
Exemplul de răspuns:
{
   "code":200,
   "data":{
      "url_id":"1388598",
      "status":"disabled",
      "short_url":"http://11x.ro/bbc",
      "date_time":"2013-04-04 17:01:42"
   }
}

Activ

Activate a disabled short url within your account.

Parametrii:
Nume: Type: Descriere:
key string Cheie de acces API. Login to view.
short_url string Base64 encoded version of your short url. base64_encode() in PHP.
Valori de returnare:
Nume: Type: Descriere:
url_id integer ID URL unic.
status string Short url status.
short_url string Short url including domain name.
date_time string Date and time of the API call. In the format yyyy-mm-dd hh:mm:ss.
Exemplul de cerere:
API Address: http://11x.ro
GET //api/v1/7a89bcbdc39bd4e3ff9145050d67ae15/shorturl/enable/short_url/BASE64_ENCODED_SHORT_URL.json
Exemplul de răspuns:
{
   "code":200,
   "data":{
      "url_id":"1388598",
      "status":"active",
      "short_url":"http://11x.ro/bbc",
      "date_time":"2013-04-04 17:01:42"
   }
}

Info

Get detailed information for any short url within your account.

Parametrii:
Nume: Type: Descriere:
key string Cheie de acces API. Login to view.
short_url string Base64 encoded version of your short url. base64_encode() in PHP.
Valori de returnare:
Nume: Type: Descriere:
url_id integer ID URL unic.
short_url string Short url including domain name.
short_url_part string Short url part. (excluding domain name)
original_url string The original decoded long url.
date_created string Data/ora cand a fost creeat.
last_accessed string Data/ora cand a fost ultima data accesat.
total_visits integer Total vizitatori
has_password bool Fie URL-ul are nevoie de o parolă pentru a fi accesat.
expiry_date string Data/ora cand va fi sters.
status string Short url status.
date_time string Date and time of the API call. In the format yyyy-mm-dd hh:mm:ss.
Exemplul de cerere:
API Address: http://11x.ro
GET //api/v1/7a89bcbdc39bd4e3ff9145050d67ae15/shorturl/info/short_url/BASE64_ENCODED_SHORT_URL.json
Exemplul de răspuns:
{
   "code":200,
   "data":{
      "url_id":"13423436",
      "short_url":"http://11x.ro/bbc",
      "short_url_part":"bbc",
      "original_url":"http://www.bbc.co.uk",
      "date_created":"2013-04-04 12:36:09",
      "last_accessed":"2013-05-02 12:32:05",
      "total_visits":"3452",
      "has_password":true,
      "expiry_date":"2019-03-02 23:59:59",
      "status":"active",
      "date_time":"2013-04-04 17:10:14"
   }
}

List

List all active urls within your account.

Parametrii:
Nume: Type: Descriere:
key string Cheie de acces API. Login to view.
Valori de returnare:
Nume: Type: Descriere:
urls array Listă de URL-uri scurte.
date_time string Date and time of the API call. In the format yyyy-mm-dd hh:mm:ss.
Exemplul de cerere:
API Address: http://11x.ro
GET //api/v1/7a89bcbdc39bd4e3ff9145050d67ae15/shorturl/list_active_urls.json
Exemplul de răspuns:
{
   "code":200,
   "data":{
      "urls":[
         {
            "short_url":"http://11x.ro/2F"
         },
         {
            "short_url":"http://11x.ro/2q"
         }
      ],
      "date_time":"2013-04-09 09:48:05"
   }
}

Copyright © 2017 - Scurteaza URL. Designed by SkinDesign - Cluj-Napoca.
English (en)Romanian (RO)

Statistici T5