// // ShrtySvcConst.h // // Copyright (c) 2009, Robert R. Fahrni // All rights reserved. // // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: // // 1. Redistributions of source code must retain the above copyright notice, // this list of conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright notice, // this list of conditions and the following disclaimer in the documentation and/or // other materials provided with the distribution. // 3. Neither the name of the author nor the names of its contributors may be // used to endorse or promote products derived from this software without specific // prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS // OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY // AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER // IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT // OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // extern NSString* const kShrtyGoodResult; // = @"0"; extern NSString* const kGoodPrefix; // = @"http"; extern NSInteger const kGoodPrefixLen; // = 4; // tr.im constants // http://api.tr.im/api/trim_url.xml?url=http://www.google.com extern NSString* const kShrtyTrimSvcName; // = @"tr.im"; extern NSString* const kShrtyTrimSvcURL; // = @"http://api.tr.im/api/"; extern NSString* const kShrtyTrimSvcShortenMethod; // = @"trim_url.xml?"; extern NSString* const kShrtyTrimSvcShortenArgs; // = @"url=%@"; extern NSString* const kShrtyTrimSvcExpandMethod; // = @"trin_destination.xml?"; extern NSString* const kShrtyTrimSvcExpandArgs; // = @"trimpath=%@"; // ping.fm constants extern NSString* const kShrtyPingFmSvcName; // = @"ping.fm" extern NSString* const kShrtyPingFmSvcURL; // = @"http://api.ping.fm/v1/"; extern NSString* const kShrtyPingFmSvcShortenMethod; // = @"url.create?"; extern NSString* const kShrtyPingFmSvcShortenArgsFull; // = @"api_key=%@&user_app_key=%@&long_url=%@"; extern NSString* const kShrtyPingFmSvcExpandMethod; // = @"url.resolve?"; extern NSString* const kShrtyPingFmSvcExpandArgsFull; // = @"api_key=%@&user_app_key=%@&short_url=%@"; // bit.ly constants extern NSString* const kShrtyBitlySvcName; // = @"bit.ly" extern NSString* const kShrtyBitlySvcURL; // = @"http://api.bit.ly/"; extern NSString* const kShrtyBitlySvcShortenMethod; // = @"shorten?"; extern NSString* const kShrtyBitlySvcShortenArgsFull; // = @"version=2.0.1&login=%@&apiKey=%@&longUrl=%@&format=xml"; extern NSString* const kShrtyBitlySvcShortenArgsDemo; // = @"version=2.0.1&longUrl=%@&login=bitlyapidemo&apiKey=R_0da49e0a9118ff35f52f629d2d71bf07&format=xml"; extern NSString* const kShrtyBitlySvcExpandMethod; // = @"expand?"; extern NSString* const kShrtyBitlySvcExpandArgsFull; // = @"version=2.0.1&shortUrl=%@&login=%@&apiKey=%@&format=xml"; extern NSString* const kShrtyBitlySvcExpandArgsDemo; // = @"version=2.0.1&shortUrl=%@&login=bitlyapidemo&apiKey=R_0da49e0a9118ff35f52f629d2d71bf07&format=xml"; // j.mp constants - essentially bit.ly extern NSString* const kShrtyJmpSvcName; // = @"j.mp" extern NSString* const kShrtyJmpSvcURL; // = @"http://api.j.mp/"; extern NSString* const kShrtyJmpSvcShortenMethod; // = @"shorten?"; extern NSString* const kShrtyJmpSvcShortenArgsFull; // = @"version=2.0.1&login=%@&apiKey=%@&longUrl=%@&format=xml"; extern NSString* const kShrtyJmpSvcShortenArgsDemo; // = @"version=2.0.1&longUrl=%@&login=bitlyapidemo&apiKey=R_0da49e0a9118ff35f52f629d2d71bf07&format=xml"; extern NSString* const kShrtyJmpSvcExpandMethod; // = @"expand?"; extern NSString* const kShrtyJmpSvcExpandArgsFull; // = @"version=2.0.1&shortUrl=%@&login=%@&apiKey=%@&format=xml"; extern NSString* const kShrtyJmpSvcExpandArgsDemo; // = @"version=2.0.1&shortUrl=%@&login=bitlyapidemo&apiKey=R_0da49e0a9118ff35f52f629d2d71bf07&format=xml"; // su.pr constants // E.G. -- http://su.pr/api/shorten?longUrl=http://www.stumbleupon.com&format=xml extern NSString* const kShrtySuprSvcName; // = @"su.pr" extern NSString* const kShrtySuprSvcURL; // = @"http://su.pr/api/"; extern NSString* const kShrtySuprSvcShortenMethod; // = @"shorten?"; extern NSString* const kShrtySuprSvcShortenArgs; // = @"longUrl=%@&format=xml"; extern NSString* const kShrtySuprSvcExpandMethod; // = @"expand?"; extern NSString* const kShrtySuprSvcExpandArgs; // = @"shortUrl=%@&format=xml"; // YOURLS constants -- See yourls.com for more information. // E.G. -- http://yoururl.com/yourls-api.php?url=http://rob.crabapples.net&format=xml&action=shorturl extern NSString* const kShrtyYOURLSSvcName; // = @"YOURLS" extern NSString* const kShrtyYOURLSSvcURL; // There isn't just one of these, provide the path to your YOURLS based shortener extern NSString* const kShrtyYOURLSSvcShortenMethod; // = @"yourls-api.php?"; extern NSString* const kShrtyYOURLSSvcShortenArgsFull; // = @"format=xml&action=shorturl&username=%@&password=%@&url=%@"; extern NSString* const kShrtyYOURLSSvcShortenArgs; // = @"format=xml&action=shorturl&url=%@"; extern NSString* const kShrtyYOURLSSvcExpandMethod; // = @"yourls-api.php?"; extern NSString* const kShrtyYOURLSSvcExpandArgsFull; // = @"format=xml&action=expand&username=%@&password=%@&shorturl=%@"; extern NSString* const kShrtyYOURLSSvcExpandArgs; // = @"format=xml&action=expand&shorturl=%@"; // is.gd constants -- See http://is.gd/api_info.php for more information // E.G. -- http://is.gd/api.php?longurl=http://www.example.com extern NSString* const kShrtyIsGdSvcName; // = @"is.gd" extern NSString* const kShrtyIsGdSvcURL; // = @"http://is.gd/"; extern NSString* const kShrtyIsGdSvcShortenMethod; // = @"api.php?"; extern NSString* const kShrtyIsGdSvcShortenArgs; // = @"longurl=%@"; extern NSString* const kShrtyIsGdSvcExpandMethod; // NOT SUPPORTED extern NSString* const kShrtyIsGdSvcExpandArgs; // NOT SUPPORTED // u.nu constants -- See http://u.nu/unu-api for more information // E.G. -- http://u.nu/unu-api-simple?url=http://rob.crabapples.net/ extern NSString* const kShrtyUnuSvcName; // = @"u.nu" extern NSString* const kShrtyUnuSvcURL; // = @"http://u.nu/"; extern NSString* const kShrtyUnuSvcShortenMethod; // = @"unu-api-simple?"; extern NSString* const kShrtyUnuSvcShortenArgs; // = @"url=%@"; extern NSString* const kShrtyUnuSvcExpandMethod; // NOT SUPPORTED extern NSString* const kShrtyUnuSvcExpandArgs; // NOT SUPPORTED // tinyarro.ws constants -- See http://tinyarro.ws/info/api for more information // http://tinyarro.ws/api-create.php?utfpure=1&url=http://www.yumbunny.com extern NSString* const kShrtyTinyArrowsSvcName; // = @"tinyarro.ws" extern NSString* const kShrtyTinyArrowsSvcURL; // = @"http://tinyarro.ws/"; extern NSString* const kShrtyTinyArrowsSvcShortenMethod;// = @"api-create.php?"; extern NSString* const kShrtyTinyArrowsSvcShortenArgs; // = @"utfpure=1&url=%@"; extern NSString* const kShrtyTinyArrowsSvcExpandMethod; // NOT SUPPORTED extern NSString* const kShrtyTinyArrowsSvcExpandArgs; // NOT SUPPORTED