sebonlien / bitly-api

Automatically exported from code.google.com/p/bitly-api
0 stars 0 forks source link

v2 /shorten seems to be ignoring domain #35

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem (provide an exact http api call where
appropriate)?

Send a request to a version 2 url seems to be ignoring the requested domian.

1. Request URL: 

http://api.j.mp/shorten?login=globocore&version=2.0.1&apiKey=R_9a3a17fe7ab262e23
e72f853bd46fcdd&format=json&longUrl=http%3A%2F%2Fmyurl.com%2Fsome_url%2F

2. Response: 

{"errorCode": 0, "errorMessage": "", "results": {"http://myurl.com/some_url/": 
{"userHash": "cmjTQg", "shortKeywordUrl": "", "hash": "c9vu62", 
"shortCNAMEUrl": "http://bit.ly/cmjTQg", "shortUrl": "http://bit.ly/cmjTQg"}}, 
"statusCode": "OK"}

What is the expected output? What do you see instead?

Expected response: '{"errorCode": 0, "errorMessage": "", "results": 
{"http://myurl.com/some_url/": {"userHash": "cmjTQg", "shortKeywordUrl": "", 
"hash": "c9vu62", "shortCNAMEUrl": "http://j.mp/cmjTQg", "shortUrl": 
"http://j.mp/cmjTQg"}}, "statusCode": "OK"}'

What version of the product are you using? On what operating system?
Version 2.0.1 tested on a Mac Snow Leopard and a Ubuntu 9

Please provide any additional information below.

This was working fine until yesterday.

Original issue reported on code.google.com by vanessa....@gmail.com on 24 Feb 2011 at 5:05

GoogleCodeExporter commented 8 years ago
Thanks for reporting this.

V2 endpoints have been deprecated since May 2010, you should consider upgrading 
to v3 endpoints documented at http://api.bit.ly/

The way to make this api call in v3 is 
http://api.bitly.com/v3/shorten?login=...&apiKey=...&longUrl=...&domain=j.mp

Original comment by jehiah on 24 Feb 2011 at 5:13

GoogleCodeExporter commented 8 years ago
Oops, didn't know it was deprecated. Do you know when/if the url for v2 will no 
longer respond?

Original comment by vanessa....@gmail.com on 24 Feb 2011 at 5:53