https://www.mediawiki.org/w/api.php?action=help&modules=query%2Binfo
        https://www.mediawiki.org/wiki/API:Info
191890
def info(
            self,
            page: 'WikipediaPage'
    ) -> 'WikipediaPage':
        
        params = {
            'action': 'query',
            'prop': 'info',
            'titles': page.title,
            'inprop': '|'.join([
                'protection',
                'talkid',
                'watched',
                'watchers',
                'visitingwatchers',
                'notificationtimestamp',
                'subjectid',
                'url',
                'readable',
                'preload',
                'displaytitle'
            ])
        }
        raw = self._query(
            page,
            params
        )
        self._common_attributes(raw['query'], page)
        pages = raw['query']['pages']
        for k, v in pages.items():
            if k == '-1':
                page._attributes['pageid'] = -1
                return page
            else:
                return self._build_info(v, page)
        return page
1232311
function() {
		var api_url,
			self = this;
					
		// Create Dom element
		this._el.content_item = TL.Dom.create("div", "tl-media-twitter", this._el.content);
		this._el.content_container.className = "tl-media-content-container tl-media-content-container-text";
		
		// Get Media ID
		var found = this.data.url.match(/(status|statuses)\/(\d+)/);
		if (found && found.length > 2) {
		    this.media_id = found[2];
		} else {
		    self.loadErrorDisplay(self._("twitterembed_invalidurl_err"));
		    return;
		}

		// API URL
		api_url = "https://api.twitter.com/1/statuses/oembed.json?id=" + this.media_id + "&omit_script=true&include_entities=true&callback=?";
        
        window.twttr = (function(d, s, id) {
            var js, fjs = d.getElementsByTagName(s)[0],
            t = window.twttr || {};
            if (d.getElementById(id)) return t;
            js = d.createElement(s);
            js.id = id;
            js.src = "https://platform.twitter.com/widgets.js";
            fjs.parentNode.insertBefore(js, fjs);

            t._e = [];
            t.ready = function(f) {
            t._e.push(f);
            };

            return t;
        }(document, "script", "twitter-wjs"));
        
        mediaID = this.media_id;
		
		// API Call
		TL.ajax({
			type: 'GET',
			url: api_url,
			dataType: 'json', //json data type
			success: function(d){
				self.createMedia(d);
			},
			error:function(xhr, type){
				var error_text = "";
				error_text += self._("twitter_load_err") + "<br/>" + self.media_id + "<br/>" + type;
				self.loadErrorDisplay(error_text);
			}
		});
		 
	}
50830
public function getVideoInfo($url)
    {
        if (!empty($url)) {
            if (strpos($url, 'youtube')) {
                preg_match('/(?<=v(\=|\/))([-a-zA-Z0-9_]+)|(?<=youtu\.be\/)([-a-zA-Z0-9_]+)/', $url, $v);
                $provider = 'youtube';
                $url_data = sprintf($this->_youtubeVideoApi, $v[0]);
            } elseif (strpos($url, 'vimeo')) {
                preg_match('(\d+)', $url, $id);
                $provider = 'vimeo';
                $url_data = sprintf($this->_vimeoVideoApi, $id[0]);
            }

            switch ($provider) {
                case 'youtube':
                    $ch = curl_init($url_data);  
                    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); 
                    curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: text/json')); 
                    $result = json_decode(curl_exec($ch), true);
                    curl_close($ch);

                    return array(
                        'title'       => $result['entry']['title']['$t'],
                        'description' => $result['entry']['media$group']['media$description']['$t'],
                        'thumbnail'   => $result['entry']['media$group']['media$thumbnail'][0]['url'],
                        'duration'    => $result['entry']['media$group']['media$content'][0]['duration'],
                        'upload_date' => $result['entry']['media$group']['yt$uploaded']['$t'],
                    );
                    break;

                case 'vimeo':
                    $ch = curl_init($url_data);  
                    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); 
                    curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: text/json')); 
                    $result = json_decode(curl_exec($ch), true);
                    curl_close($ch);

                    return array(
                        'title'       => $result[0]['title'],
                        'description' => $result[0]['description'],
                        'thumbnail'   => $result[0]['thumbnail_small'],
                        'duration'    => $result[0]['duration'],
                        'upload_date' => $result[0]['upload_date']
                    );
                    break;
                
                default:
                    return false;
                    break;
            }
        }
        return false;
    }
784657
function() {
		var api_url,
			self = this;

		// Create Dom element
		this._el.content_item	= TL.Dom.create("div", "tl-media-item tl-media-iframe tl-media-spotify", this._el.content);

		// Get Media ID
		if (this.data.url.match(/^spotify:track/) || this.data.url.match(/^spotify:album/) || this.data.url.match(/^spotify:user:.+:playlist:/)) {
			this.media_id = this.data.url;
		}

		if (this.data.url.match(/spotify\.com\/track\/(.+)/)) {
			this.media_id = "spotify:track:" + this.data.url.match(/spotify\.com\/track\/(.+)/)[1];
		} else if (this.data.url.match(/spotify\.com\/album\/(.+)/)) {
			this.media_id = "spotify:album:" + this.data.url.match(/spotify\.com\/album\/(.+)/)[1];
		} else if (this.data.url.match(/spotify\.com\/user\/(.+?)\/playlist\/(.+)/)) {
			var user = this.data.url.match(/spotify\.com\/user\/(.+?)\/playlist\/(.+)/)[1];
			var playlist = this.data.url.match(/spotify\.com\/user\/(.+?)\/playlist\/(.+)/)[2];
			this.media_id = "spotify:user:" + user + ":playlist:" + playlist;
		} else if (this.data.url.match(/spotify\.com\/artist\/(.+)/)) {
			var artist = this.data.url.match(/spotify\.com\/artist\/(.+)/)[1];
			this.media_id = "spotify:artist:" + artist;
		}


		if (this.media_id) {
			// API URL
			api_url = "https://embed.spotify.com/?uri=" + this.media_id + "&theme=white&view=coverart";

			this.player = TL.Dom.create("iframe", "tl-media-shadow", this._el.content_item);
			this.player.width 		= "100%";
			this.player.height 		= "100%";
			this.player.frameBorder = "0";
			this.player.src 		= api_url;

			// After Loaded
			this.onLoaded();

		} else {
				this.loadErrorDisplay(this._('spotify_invalid_url'));
		}
	}
306990
function get_menu_info(){
    
        $url = self::API_URI . self::MENU_INFO;
        $param['access_token'] = $this->access_token;
        $menu_url = $this->create_url($url, $param);
    
        $data = $this->http_get($menu_url);
    
        return $this->return_data($data);
    }
347017
def url_info(request):
    

    return {
        'MEDIA_URL' : core_settings.MEDIA_URL,
        'STATIC_URL': core_settings.STATIC_URL,
        'VERSION' : core_settings.VERSION,
        'SERVER_INFO' : core_settings.SERVER_INFO,
        'SITE_NAME' : current_site_name,
        'CURRENT_SITE': current_site,
    }
618877
def obtainInfo(self):

        

        try:
            info = self.ytdl.extract_info(self.yid, download=False)
        except youtube_dl.utils.DownloadError:
            raise ConnectionError

        if not self.preferences['stream']:
            self.url = (info['requested_formats'][0]['url'], info['requested_formats'][1]['url'])
            return True

        # else:
        for f in info['formats']:
            if 'filesize' not in f or not f['filesize']:
                f['filesize'] = float('inf') # next line won't fail, infinity, because unknown filesize is the least preferred

        # - for easy sorting - we'll get best quality and lowest filsize
        aud = {(-int(f['abr']),    f['filesize'], f['url']) for f in info['formats'] if f.get('abr') and not f.get('height')}
        vid = {(-int(f['height']), f['filesize'], f['url']) for f in info['formats'] if not f.get('abr') and f.get('height')}
        full= {(-int(f['height']), f['filesize'], f['url']) for f in info['formats'] if f.get('abr') and f.get('height')}

        try:
            _f = int( self.preferences.get('format') ) # if valid format is present, then choose closes value
            _k = lambda x: abs(x[0] + _f) # +, because x[0] is negative

        except (ValueError, TypeError):
            _k = lambda d: d

        if self.preferences['audio'] and self.preferences['video']: fm = sorted(full, key=_k)
        elif self.preferences['audio']: fm = sorted(aud, key=_k)
        elif self.preferences['video']: fm = sorted(vid, key=_k)

        filesize = 0
        i = -1

        try:
            while filesize == 0: # some videos are problematic, we will try to find format with non-zero filesize

                i += 1

                self.url = fm[i][2]
                if fm[i][1] == float('inf'):
                    filesize = int(self.r_session.head(self.url).headers['content-length'])
                else:
                    filesize = int(fm[i][1])

        except IndexError: # finding filesize failed for every format

            self.url = (info['requested_formats'][0]['url'], info['requested_formats'][1]['url'])
            self.preferences['stream'] = False # hopefully non-stream download will work

            return True

        self.filesize = filesize

        return True
320713
public function getMediaWithHttpInfo($media_id, $is_video = false)
    {
        if (!$this->access_token && !$this->getAccessToken()) {
            return false;
        }
        $url_prefix = $is_video ? str_replace('https', 'http', self::API_URL_PREFIX) : self::API_URL_PREFIX;
        $url = $url_prefix . self::MEDIA_GET_URL . "access_token={$this->access_token}" . '&media_id=' . $media_id;
        $oCurl = curl_init();
        if (stripos($url, "https://") !== false) {
            curl_setopt($oCurl, CURLOPT_SSL_VERIFYPEER, false);
            curl_setopt($oCurl, CURLOPT_SSL_VERIFYHOST, false);
            curl_setopt($oCurl, CURLOPT_SSLVERSION, 1);
        }
        curl_setopt($oCurl, CURLOPT_URL, $url);
        curl_setopt($oCurl, CURLOPT_RETURNTRANSFER, 1);
        $sContent = curl_exec($oCurl);
        $aStatus = curl_getinfo($oCurl);
        $result = array();
        if (intval($aStatus["http_code"]) !== 200) {
            return false;
        }
        if ($sContent) {
            if (is_string($sContent)) {
                $json = json_decode($sContent, true);
                if (isset($json['errcode'])) {
                    $this->errCode = $json['errcode'];
                    $this->errMsg = $json['errmsg'];
                    return $this->checkRetry(__FUNCTION__, func_get_args());
                }
            }
            $result['content'] = $sContent;
            $result['info'] = $aStatus;
            return $result;
        }
        return false;
    }
607176
static function _fetch_plugin_info_from_repository( $action, $args ) {
            $url = $http_url = 'http://api.wordpress.org/plugins/info/1.0/';
            if ( $ssl = wp_http_supports( array( 'ssl' ) ) ) {
                $url = set_url_scheme( $url, 'https' );
            }

            $args = array(
                'timeout' => 15,
                'body'    => array(
                    'action'  => $action,
                    'request' => serialize( $args )
                )
            );

            $request = wp_remote_post( $url, $args );

            if ( is_wp_error( $request ) ) {
                return false;
            }

            $res = maybe_unserialize( wp_remote_retrieve_body( $request ) );

            if ( ! is_object( $res ) && ! is_array( $res ) ) {
                return false;
            }

            return $res;
        }
809140
def info(self, name):
        """"""
        r = requests.get('{}/{}'.format(self.url_service, name))
        return r.json()
144719
def get_file_info(hash, context=None):
    
    if context is None:
        stmt = _get_sql('get-file-info.sql')
        args = dict(hash=hash)
    else:
        stmt = _get_sql('get-file-info-in-context.sql')
        id, version = get_id_n_version(context)
        args = dict(hash=hash, id=id, version=version)

    with db_connect() as db_conn:
        with db_conn.cursor() as cursor:
            cursor.execute(stmt, args)
            try:
                filename, media_type = cursor.fetchone()
            except TypeError:
                raise FileNotFound(hash)
    return filename, media_type
955277
def info(self, page, version=None):
        
        return (self._dokuwiki.send('wiki.getPageInfoVersion', page, version)
                if version is not None
                else self._dokuwiki.send('wiki.getPageInfo', page))
1304937
def get_media_requests(self, item, info):
        
        key_generator = item.get(self.QINIU_KEY_GENERATOR_FIELD)
        return [Request(x, meta={'qiniu_key_generator': key_generator}) for x in item.get(self.FILES_URLS_FIELD, [])]
1322005
public void toMediaWiki(
      final String username, final String password, final String url, final String title)
      throws GitChangelogRepositoryException, GitChangelogIntegrationException {
    new MediaWikiClient(url, title, render()) //
        .withUser(username, password) //
        .createMediaWikiPage();
  }
979066
def webhelp(i):
    
    a=i.get('repo_uoa','')
    m=i.get('module_uoa','')
    duoa=i.get('data_uoa','')

    url=cfg['wiki_data_web']

    if m!='':
       if duoa=='': 
          duoa=m
          m=cfg['module_name']

       r=find_path_to_data({'repo_uoa':a, 'module_uoa':m, 'data_uoa':duoa})
       if r['return']>0: return r
       p=r['path']

       rx=convert_entry_to_cid(r)
       if rx['return']>0: return rx

       cuoa=rx['cuoa']
       cid=rx['cid']
       xcuoa=rx['xcuoa']
       xcid=rx['xcid']

       # Prepare URL
       url+=cid.replace(':','_')

    out('Opening web page '+url+' ...')

    import webbrowser
    webbrowser.open(url)

    return {'return':0}
975054
def __load(self, redirect=True, preload=False):
        
        query_params = {
            "prop": "info|pageprops",
            "inprop": "url",
            "ppprop": "disambiguation",
            "redirects": "",
        }
        query_params.update(self.__title_query_param())

        request = self.mediawiki.wiki_request(query_params)

        query = request["query"]
        pageid = list(query["pages"].keys())[0]
        page = query["pages"][pageid]

        # determine result of the request
        # missing is present if the page is missing
        if "missing" in page:
            self._raise_page_error()
        # redirects is present in query if page is a redirect
        elif "redirects" in query:
            self._handle_redirect(redirect, preload, query, page)
        # if pageprops is returned, it must be a disambiguation error
        elif "pageprops" in page:
            self._raise_disambiguation_error(page, pageid)
        else:
            self.pageid = pageid
            self.title = page["title"]
            self.url = page["fullurl"]
707364
function info($plugin_name)
	{
		if(isset($this->plugins[$plugin_name])) return $this->plugins[$plugin_name];
		return false;
	}