https://bugzilla.wikimedia.org/show_bug.cgi?id=29237

       Web browser: ---
             Bug #: 29237
           Summary: add interwiki target url attribute to
                    api/query/interwiki
           Product: MediaWiki
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: Unprioritized
         Component: API
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected], [email protected],
                    [email protected], [email protected]
    Classification: Unclassified


Please return the target url if a title contains an interwiki prefix like
prop=langlinks&llurl=1 does.

At the momment it it not always possible to know the target url of an interwiki
link. For language links llurl can be used which solves the problem.
/api/query/interwiki only contains the interwiki prefix (@iw) without an
possibility to request the url. Not all prefix are contained in the sitematrix
(see bug 28743 / bug 19838), so there is no other sure possibility the build
the url of the interwikitarget by your own.

My suggestion would be to add a new parameter interwikiurl, so that
http://de.wikipedia.org/w/api.php?action=query&titles=en:Main%20Page&redirects=&interwikiurl=1
returns
<api>
  <query>
    <interwiki>
      <i title="en:Main Page" iw="en" iwurl="http://en.wikipedia.org/wiki/Main
Page"/>
    </interwiki>
  </query>
</api>

New the iwurl attributes should return the same value like
/api/query/pages/page/langlinks/ll/@url on querying prop=langlinks&url=1

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to