Important: Tr.im API is in Beta
Edit a short link's title
*Important: User (x-api-key) must be owner of short link associated with keyword
Url: /links/{keyword}/edit
Method: PUT
Request
Parameter |
Type |
Description |
Required |
title |
string |
title for short link |
true |
Response
Parameter |
Type |
Description |
link |
json |
link details |
An Example Request
PUT /links/{keyword}/edit HTTP/1.1
x-api-key: 2a4ff74ee231de46d73f86777d20d96c
Content-Type: application/json
{"title": "HelloWorld"}
An Example Response
200 (Success)
{"link":{"clicksCount":8,"id":1834978,"short_url":"stage.tr.im\/newkeyword","long_url":"https:\/\/www.facebook.com\/wikipedia","user_id":{"id":10429},"client_ip":"38.140.30.50","is_archived":0,"is_spam":false,"page_title":"HelloWorld","created_at":"2015-07-14T07:47:55+0000","targets":[],"link_aliases":[{"id":77,"short_url":"stage.tr.im\/zk1y6","alias_created_date":"2015-07-14T13:21:47+0000","is_spam":false}],"link_tags":[{"unacceptable_chars":[",",";","\n","\t"],"id":61,"tag":"222"},{"unacceptable_chars":[",",";","\n","\t"],"id":62,"tag":"222222"}]}}
Example Error Responses
-
500 Internal Server Error, An Exception was thrown while handling: Method Not Allowed
- {"code":400,"message":"Validation Failed","errors":{"errors":["You need to pass at least one parameter"],"children":{"title":{},"keyword":{},"tags":{}}}}
-
403 Forbidden {"Forbidden":"Authentication Failed."}
Comments