title: Getting data inside of button. BS4 + Requests
body: <p><code>&lt;button class=&quot;add-to-cart btn btn-primary&quot; data-buttontext=&quot;Add to Cart&quot; data-gtmdata='{&quot;productInfo&quot;:{&quot;sku&quot;:&quot;225169&quot;,&quot;productID&quot;:&quot;11108140&quot;,&quot;name&quot;:&quot;PlayStation 5&quot;,&quot;category&quot;:&quot;Video Games/PlayStation 5/Consoles&quot;,&quot;brand&quot;:&quot;Sony&quot;,&quot;subGenre&quot;:&quot;&quot;,&quot;platform&quot;:&quot;PlayStation 5&quot;,&quot;condition&quot;:&quot;New&quot;,&quot;variant&quot;:&quot;New&quot;,&quot;genre&quot;:&quot;&quot;,&quot;availability&quot;:&quot;Not Available&quot;,&quot;productType&quot;:&quot;regular&quot;,&quot;zoneSource&quot;:&quot;PDP&quot;},&quot;price&quot;:{&quot;sellingPrice&quot;:&quot;499.99&quot;,&quot;basePrice&quot;:&quot;499.99&quot;,&quot;currency&quot;:&quot;USD&quot;}}' data-pid=&quot;11108140&quot; disabled=&quot;&quot;&gt; &lt;/button&gt;</code></p>
  <p>Trying to get &quot;availability&quot;:&quot;Not Available&quot; from this.</p>
  <pre><code>import requests
  import re
  from bs4 import BeautifulSoup
  header = {&quot;User-Agent&quot;:&quot;Mozilla/5.0&quot;}
  GameStopItem = 'https://www.gamestop.com/video-games/playstation-5/consoles/products/playstation-5/11108140.html'
  r = requests.get(GameStopItem, headers=header)
  r = BeautifulSoup(r.content, 'html.parser')
  GameStopStock = r.find(class_=&quot;add-to-cart btn btn-primary&quot;)
  print(GameStopStock)
  </code></pre>