Upcoming Changes to api.steemit.com
steemit·@steemitdev·
0.000 HBDUpcoming Changes to api.steemit.com
 In as soon as 7 days (2018-12-07 23:00:00 UTC), the api.steemit.com endpoint will begin to route select steemd methods directly to hivemind. If you rely on this endpoint for any of the methods below, you should begin testing your applications against api.steemitdev.com as soon as possible. This is in preparation for the removal of `tags` and `follows` plugins from our full nodes, the functionality of which has been ported to the hivemind service. While hivemind attempts to mimic the existing request/response format as well as all of the underlying logic, there are notable exceptions which will be outlined in this post. As we disclosed in our [last post](https://steemit.com/steem/@ned/2fajh9-steemit-update), Steemit Inc.’s top priority is dramatically lowering the cost of running a Steem node. By routing these API calls to Hivemind, we greatly decrease the amount of resources our full nodes use. <h2>Background</h2> Hive's `condenser_api` implementation goal is to port a relevant subset of steemd's `tags` and `follows` functionalities to support instances of `condenser` with minimal changes required. This allows node operators to lower `steemd` resource requirements while laying the infrastructure for next-generation social APIs. While we have attempted to ensure relevant data is still available, in some cases this is simply impossible. A prime example of this is the `get_state` call, whose response is a monolith which attempts to account for an extremely wide variety of data. Portions of the returned data is irrelevant to most apps, and some of it is entirely out of hive's scope (example: witness schedule). As another example, when loading a discussion thread, all involved accounts objects are returned *in full* (including balances, authorities, statistics). This results in a lot of extra bandwidth used when only a small fraction of the information is relevant. In some cases, portions of API responses unused by `condenser` have simply not been implemented in hive -- either to save time or complexity. In other cases, expected values may be slightly different but of a compatible format. Hive cannot guarantee data is accurate as of the latest block. Because interfaces often rely on supporting information such as `steem_per_vests` or `feed_price`, hive does store and return some marginally-out-of-scope-yet-accessible data, but it will be cached with a TTL of up to several minutes. Those values can still be obtained through other API calls to steemd. ----- <h1>API Changes - Overview</h1> We will migrate the API by *overriding* specific steemd methods passed to api.steemit.com. These methods will now be served by hivemind: ``` Follows Queries get_followers [following, start_follower, follow_type, limit] get_following [follower, start_following, follow_type, limit] get_follow_count [account] Content Monolith get_state [path] Trending Tags get_trending_tags [start_tag, limit] (!) only supports ('', 250) Discussion Queries get_discussions_by_trending {tag, limit, start_author, start_permlink} trending get_discussions_by_hot {tag, limit, start_author, start_permlink} hot get_discussions_by_promoted {tag, limit, start_author, start_permlink} promoted get_discussions_by_created {tag, limit, start_author, start_permlink} created get_discussions_by_blog {tag, limit, start_author, start_permlink} account-blog get_discussions_by_feed {tag, limit, start_author, start_permlink} account-feed get_discussions_by_comments {limit, start_author, start_permlink} account-comments get_replies_by_last_update [author, permlink, limit]; account-replies ``` #### Exceptions These calls will NOT be forwarded to hivemind, and will be forwarded to a light steemd node: ``` get_state.params=['@<user>/transfers'] get_state.params=['~witnesses'] ``` ### Not ported ``` Deprecated/Unused Discussion Queries - NOT ported! get_post_discussions_by_payout {tag, limit, start_author, start_permlink} payout get_comment_discussions_by_payout {tag, limit, start_author, start_permlink} payout_comments get_discussions_by_cashout {tag, limit, start_author, start_permlink} UNUSED/cashout get_discussions_by_children {tag, limit, start_author, start_permlink} UNUSED/responses get_discussions_by_votes {tag, limit, start_author, start_permlink} UNUSED/votes get_discussions_by_active {tag, limit, start_author, start_permlink} DEPRECATED get_discussions_by_trending30 {tag, limit, start_author, start_permlink} DEPRECATED (DNE) get_discussions_by_payout {tag, limit, start_author, start_permlink} UNUSED (DNE) get_discussions_by_author_before_date [author, start_permlink, before_date, limit] UNUSED ``` <br> Additionally, the following have not been ported, which means they may become unavailable. ``` get_feed_entries() get_feed() get_blog_entries() get_blog() get_account_reputations() get_reblogged_by() get_blog_authors() get_tags_used_by_author() ``` <br> These *may* be available for some time, but will be served by a light node. We cannot guarantee their availability. Many of these calls are very similar (or identical) to one of the supported methods. If this is not the case, please leave a comment and we'll evaluate the options. <h3>Not ported, still available through steemd's condenser_api</h3> As these are still part of consensus and consumers often expect them to be 100% accurate and up-to-date, they are not currently served by hivemind and will continue to be available through steemd. ``` Content Primitives get_content [author, permlink] get_content_replies [parent_author, parent_permlink] get_active_votes [author, permlink] get_account_votes [account] ``` <h2>Steemd configuration changes</h2> After a period of testing, the `follow` and `tags` plugins will be removed from our API nodes. We will however add the `reputation` plugin, which allows us to continue using the existing reputation metrict. It used to be a subset of `follow` plugin functionality, and it's the only piece logic which is not easily reproducible outside of steemd. If you were relying on reputation methods provided by `follow_api`, you will need to update your code to use `reputation_api`. ----- ## API Changes - Detail ### Legacy `call` method ``` call ['condenser_api', method, params] ``` The legacy-style `call` method takes `[api, method, [params]]` as parameters. Hive routes these calls to the appropriate internal method. ##### Concerns - `api` *must* be set to `condenser_api` - It is not recommended to use this method --- ### Follows Queries ``` condenser_api.get_followers condenser_api.get_following condenser_api.get_follow_count ``` These are straightforward, simple replacements. ##### Concerns - steemd follows plugin can hold multiple follow 'states'; hive enforces one - the feature is undocumented but small chance of edge cases - internally, hive follow state must be blank, followed or muted --- ### Content Primitives ``` condenser_api.get_content condenser_api.get_content_replies ``` <br> **Important**: while hive offers these methods as part of its `condenser_api`, api.steemit.com will continue to serve these directly from `steemd`. However, hive does leverage it internally to build responses for `get_state` as well as the various `get_discussions_*` methods. ##### Concerns - hive's `comment` response format is a subset of steemd's. - deprecated/useless fields have been removed or normalized - some fields of questionable utility are not unimplemented --- ### Content Monolith ``` condenser_api.get_state ``` Notice! Hive will refuse to serve these routes: - `/@account/transfers` - `/witnesses` and `/~witnesses` Hive does serve these routes, requested by condenser, which are not mapped to anything, but steemd handles them anyway: - `/@account/followed` - dummy - `/@account/followers` - dummy - `/@account/permissions` - dummy - `/@account/password` - dummy - `/@account/settings` - dummy ##### Concerns - embedded get_dynamic_global_properties data is truncated - hive does not keep up-to-date keys for accounts.. but on `/@account/xxx` pages, it still serves minimal account data. --- ### Trending Tags ``` condenser_api.get_trending_tags ``` ##### Concerns - the parameters `[start_tag, limit]` must be left blank or passed as `['', 250]` - only primary tags ("category") counted in these stats (not all tags, as per current implementation) --- ### Discussion Queries **Global** ``` condenser_api.get_discussions_by_trending condenser_api.get_discussions_by_hot condenser_api.get_discussions_by_promoted condenser_api.get_discussions_by_created ``` **Account/blog-specific** ``` condenser_api.get_discussions_by_blog condenser_api.get_discussions_by_feed condenser_api.get_discussions_by_comments condenser_api.get_replies_by_last_update ``` ##### Concerns - all `get_content` concerns apply here; otherwise identical ------ <h2>Testing & Feedback</h2> **If your app or service relies on any of the above calls and uses api.steemit.com, please begin testing against api.steemitdev.com as soon as possible.** If there is an unsupported API call on which you are critically relying on, let us know in the comments and we'll find a solution. Note that at this time, no `steemd` APIs are changing -- only the API as provided by api.steemit.com. If any apps are still relying on `get_state`, we highly recommend ceasing use as soon as possible. _The Steemit Team_
👍 moemyint, phoethar01, salanlan, ballpin, chanhon, ainede, fadmer, salynn, ghosty5, ghost2, dlayshan, stater, tharshan, galannar, micaldaviddin, shyshy, kansa, simarlar, parpar, monewar, sharnsharn, poungpoung, aiteran, davidsmith1, shaungyan, dnaingkhan, laimarkan, thihan, glanter22, ntamntam, calicabre, moelout, zabatar, winewinelal, konlon, atalgyi, measureable, wai1, collect1, ddmouse, shorelee, payi, andtal, beelin, land1, matpetar, dvice, waihein, amaiman, wholeself-in, roadscape, vandeberg, inertia, oyvindsabo, igormuba, mes, newsrx, magali, themonetaryfew, f1assistance, thebluewin, donkeypong, analisa, therealwolf, yehey, crimsonclad, discordiant, salim001, garethnelsonuk, btccurrency1, z3r0d4yz, drakos, steemsportsfund, lloyddavis, steembot-general, bmwrider, pery, galinamaximova, thegoldencookie, telos, sebastianjago, inchonbitcoin, mikkolyytinen, kview, steembot-colonel, michelleh82, arama, rafelchato, fiona777, timbot606, steembot-soldier, atomrigs, pickoum, fiveboringgames, coininstant, honusurf, kdtkaren, andrewawerdna, vi1son, marcelbraendle, blockchainbilly, kristy1, themagus, jedau, yzomri, toxonaut, garvofe, elumni, goodvibrations, pilgrimtraveler, lellabird60, floridagypsy, krabgat, leviarcoin, jademont, maarnio, saamychristen, luisucv34, generation.easy, ancapwarren, sature, dgiors, frocush, stylo, carrinm, sunscape, nomadnessie, steem-meme, starrkravenmaf, sellergenius, makishart, foma17, kooshikoo, harleymechanix, jonnyrevolution, dovetail, domenicthomas, thomasgutierrez, ghostwriter82, ajay555, sjmstem, veerprit, gurunayak, innafanz, raffael, ebryans, cryptocat, mauricemikkers, angusleung100, ajvest, btcshare7, r2cornell, nepalipahad, peter-parker, mallorcaman, aidancloquell, nrajesh, dinoo, sneakgeekz, teammo, lonilush, swelker101, okkiedot, kyusho, tokyodude, boxcarblue, incomemonthly, mitchelljaworski, berlinmoonlight, shawnfishbit, daynewright, djvidov, thylbom, sirwinchester, koskl, anicasteem, cornerstone, tizswa, mytechcrunch, suorbe, evoman1, popponayashelly, michelios, bhokor, tremendospercy, jraysteem, stargarden, cryptohustler, djluka14, jkkim, happychau123, rt395, unomas, randykrafft, braini, adasq, welovegaming, eqko, bwar, jasonshick, pepskaram, efsane, mandrea, spencervogel, calvinwilliams, michaeljn, shawkr13, offoodandart, thecryptodrive, teamhumble, hopehuggs, thelindvall, sparrider, aksinya, jakechalmers, adriansky, thinksalot, lances, musicsteem, arrliinn, federacion45, fronttowardenemy, maninayton, cloh76, qwasert, gpenco, indiantraveller, doqstrader, jeffreytong, catboy, nenad-ristic, dreamcity, gindor, investlimestone, breshepard, kenjiby, marty-art, shenchensucc, andrewgenaille, steemtruth, jefflombardo, burnedpixel, nezbong, paulyaces76, kingtate, tzap90, revostrike, sportsdesk, ilbarone623, bitcoinandcoffee, mikepicker, mr-meteorologist, rahulyadav, digitalking, progressivechef, unlockrs, diggerdugg, surfyogi, albertogm, honeychum, owenwat, alvinauh, daumantas, iveta, angela.ghkh, wolfje, bl0ckchained125, toffer, chrisdavidphoto, svashta, epicdesigns, johngentry, cabbagepatch, steemvoter, honeybeee, drwom, thecryptofiend, ericarthurblair, ayobami99, jimmco, austinsandersco, redfishpillar, uzdc, protegeaa, detlev, fiftysixnorth, kona, stea90, dragon40, bargolis, revelim, marxrab, thorthur22, felander, team-leibniz, redwood419, myday, jonasthomas, daniel.errey, michaelwilshaw, vallesleoruther, ralph-rennoldson, bola, cryptastic, g-dubs, stacee, dayleeo, kbeller, arfa, nicolicreer, carlosd15, unrared, ethandsmith, forykw, ebejammin, gokulnk, clumsysilverdad, techblogger, dgarsan, iamsgr, soymanu, inquiringtimes, diabolika, st3llar, cryptoeagle, massivevibration, edrivegom, cschrader, gohba.handcrafts, kemal13, summertooth, jasonbu, mikeaga888, themadgoat, onsomewavyshit, karencarrens, weavingwords, ulfr, olegw, kam.ila, donatello, flatearth, votebank, dcrypto, echoesinthemind, mikenero, elizacheng, almvide, jockey, erikaharris, honolulu, reconnectnature, amiramnoam, moderndayhippie, yoo1900, evimeria, brandocrypto, xxcynicalkidxx, pharmacy-jinni, rainbowdash, steemit-health, zeuss11, simba, sweetieprincess, mgood, kwakumax, danielwooddesign, timmylace, goodaytraders, gumbotrader, tweeprise, silversupplement, famunger, sauravrungta, dijital, tyvain, jaredwood, cryptopet, soo.chong163, joebloggs67, steemmeupscotty, masterthematrix, abishai, tim-rumford, kpine, moon32walker, coffeetime, uwelang, joe.nobel, taryn0221, walkinharmony, nitro.live, andywong31, ligit, destinysaid, breakthrough, markperandin, shellyduncan, yourfinesight, ekavieka, mirhimayun, zaiageist, robcubbon, gmichelbkk, ratticus, kunani, apsu, gikitiki, marvel1206, mela65, williams-owb, blogger-funda, inspiration101, preciousimo, kingsman2, richmanoloriegbe, lovlu2, azharmaulana, hendragunawan, kejora05, emmywell, cryptobutton, aaronli, coretan, mcsamm, glitterbooster, kubbyelizabeth, bigdizzle91, patricksanlin, cryptoandzen, ilovedietcoke, natachayacinthe1, awolesigideon, kaylog, theagriculturist, brightex, beckenbauer, grildrig, dedmatvey, ambmicheal, nasgu, ashleypeat, cryptogem, bartosz546, brianturner, mcmusic, mamadini, plumey, kontora, freethink, tagsplanet, altertrader, jimbobbill, emonemolover, ashleykalila, dreday20, rerez, learnandteach01, olusolaemmanuel, truthly, remind-me, jerrywjl, saleg25, joechiappetta, bitbarrie, randyw, aurimo, saunter, movieperminute, stahlberg, jerseynash, spaceginger, artwithflo, steemdragon, panamapilgrim, winniex, lordnigel, axeman, masonmiler, zneeke, deluge, cuttie1979, positivibes, jmurphy074, johnthompson, shawnamawna, datascience, germansailor, kaczynski, ozgurcinarli, juvyjabian, brianphobos, revisesociology, jrhughes, gordonovich, anothersteemer, mitchiesfoodrace, soul-thru-da-ink, benjamin.still, kiddarko, tamsguitar, bssman, perspective, tfame3865, xpilar, clemdane, prosirius, nat5an, smyle, nelkeljdm, groovekeeper, gomatthew, fivefiveeleven, steemitbc, yandot, onealfa, razack-pulo, tosuccess, chron, allizz, pcste, lordkalki8, ffodie, takeone, biggy-ewu, joshbillings, foways, boyelleq, chann, echoatmajaputra, iamfo, dedyrendra, maboklagi, postnice, jalaluddinmusa, zanis, calaber24p, agusscout, chandrayunita, teukurival, sittishabir, yunidf, saidqautsar, kutrulaju, agusriandi, drowkeudrow, steem-rescue, arrahman90, galakdroneuh, heruwahyudi, mldav, alhidayat, cecyle, sfa, muhibpaya2, sitapak, xlbooster, resteemvoter, rikanurrizki, mandra, portalbireuen, muhdine, dekpah, josephsavage, ghaisan, virtaco300cc, sanne, zharifa, steemspeed, ekafao, sneakyninja, epan35, world-travel-pro, yasu, rivalhw, k-syusteem, fikar22, elangzone, fadliloways, geke, mindszai, whiessl, yenipaola, tshering-tamang, sean-king, steemed-open, claraking, karlin, masteranibal, lewis831, engineeringsteem, didic, mfconcept, bestlife, arrihan, cecicastor, spenceryan, cryptokraze, autofreak, eggmeister, rabonee, nice2us, majordon, julietj, ttay, goldsmile, kaybee1, strongminded, tenacious, dival, pretzelgirlsandy, steembirds, scandinavianlife, johnwjr7, vcelier, archet, anwarabdullah, yeni, misbahjuli, zaim4d1, vikar, helmibireuen, hendrimirza, jauharialz, dominiqueguitars, johnlue, bhmcintosh, jza, peacefulpatriot, grapthar, dabeckster, lstack, onthax, liberty-minded, nyinyiwin, kingsolo, femseen, lymepoet, magmadrome26, testing123, jonnyla08, andrewharland, zacharylutes, steemexplorers, whynotdoit, pastbastard, cryptosludge, nilfanif, percygeorge, fernowl13, mountainjewel, tobaloidee, yassine2014, eccles, sensation, timcliff, jagged, altportal, hkniazi, movingman, mal402, hogansch, cstrimel, alokchitri, beekerst, matthewwarn, darrenclaxton, odinsplayground, borran, earthnation, sandalphon, johnvibes, jonas.inuk, triviastreak, martinphoto, mohsen63, sblue, consciousangel7, wolf09, nenio, yallapapi, tastetwist, dr-frankenstein, achim03, toxichustle, fourfourfun, steemit-foodie, steemsports-ita, toocurious, berlin-park, ingapete, bullsvsbears, unlimitedorizons, bulma, technoguy, rtick, blockchaindeal, aldentan, warmcracklesound, holsturr, cryptoprofessor, lousapphire, daltono, landern, sidibeat, bulleric, sho-t, sleepingcowboy, ola-haukland, bibirider, blinkybill, dan-atstarlite, achlord, tidylive, torrey.blog, freiheit50, chris4210, omra-sky, diginomad, zhef, gmedley, bamboozled, edgarsart, agrostis, pkalra, monstermadness, sabine-reichert, diana.feuerberg, lkvictor2005, star-wars-77, goofyu, nicolaepavelean, midnight-snack, zemer, imtase, siratl, pataty69, claret, martusamak, tixinhacapitinha, joaorafael, micaelacf, enlighted, duarte9sousa, munhenhos, bhaski, inespereira, arcange, aldoman-75, ab4uw, mauerpark, demartini, brian-rhodes, truth-be-told, superstar, theghost1980, raphaelle, wisekricket, dftba, tbtek, awesomegames007, thejohalfiles, etcmike, badripanda, vikx, revdocwelch, konelectric, cafedecoral, yeungpingchi, theguruasia, leunghakkwun, gcalex, tychoxi, lukestokes, steemfucker, emmasumner, qonq99, yury-vas, mjhomb, fabien, zeroex, kamikaze, steemmillionaire, gigatoride, spiritabsolute, smjn, tarazkp, wesleybos, the-alien, ryanlj, void, joeblack1, roelandp, chrisrice, tommy-gun, d-zero, vimukthi, g0nr0gue, z3ll, steemchiller, harvhat, pharesim, meeseeks6, slowwalker, saffisara, dstors, yifeiliu, xeroc, pele23, sisygoboom, ilmadacosta, wehmoen, sudutpandang, delicious-kimchi, proof-of-stake, dylanhobalart, mysearchisover, asraful-mim, stricker, zaibkang, byaritzab,