title: How to pull data from another website using Javascript or jQuery (cross-domain) CORS (no api)
body: <p>The goal is to get the total number of members in the telegram group. This number has a unique css identifier and should be able to get pulled via jsoup or another method..</p>
  <p>Using telegram api requires auth tokens and using this method I am trying to work around any api keys that could end up getting used elsewhere as this code will be used on an open source project and could have the keys end up being leaked.</p>
  <p>I am trying to pull data from this website: <code>https://api.allorigins.win/raw?url=https://tgstat.com/en/channel/@addStickers</code></p>
  <p>The CSS selector for the total group members is <code>.columns.large-2.medium-4.small-6.margin-bottom15 &gt; div &gt; .align-center &gt; #text</code></p>
  <p>The code I am using is a bit outdated.</p>
  <pre><code>&lt;script type=&quot;text/javascript&quot;&gt;
  
  
  
   fetch('https://api.allorigins.win/raw?url=https://api.allorigins.win/raw?url=https://tgstat.com/en/channel/@addStickers').then(function(response) {
   response.html().then(function(members){
      
      members.forEach(function(member){
        document.getElementById(&quot;tg-members&quot;).innerHTML = (.columns.large-2.medium-4.small-6.margin-bottom15 &gt; div &gt; .align-center &gt; #text)
      });
    });
  }).catch(err =&gt; console.error(err));
  
  
   &lt;/script&gt;
  </code></pre>
  <p>I know I am doing something wrong just not sure exactly. Any help is appreciated.</p>
  <p>It does not have to be with fetch, could be with jQuery.. essentially I just need to get the number of members in plain html format to be displayed via document.getElementById</p>