Загрузка...

How to indicate the region in Lolzteam API (Market)?

Thread in Resolved questions created by doonati Jul 4, 2025. 85 views

  1. doonati
    Code
    forum = Forum(token=token)
    market = Market(token=token)

    def main():
    response = market.categories.telegram.get(
    pmin=10, pmax=50, origin='autoreg',
    sb=False, nsb=True, nsb_by_me=1, daybreak=7,
    premium='no', password='no', spam='no', order_by='price_to_up',
    telegram_country='US'
    )
    items = response.json().get('items', [])

    filtered_items = [
    {

    'telegram_country': item['telegram_country']
    }
    for item in items
    ]

    return filtered_items[1]

    print(main())
    шалом, делаю код для маркета, есть трабл, не понимаю, как передавать нужный рг, пробовал : locate, telegram_country, coutnry. всеровно выдает не нужный рг, типо BB/BM.
    А мне US надо
     
  2. Апатия
    Апатия Jul 4, 2025 444 1240 Jun 15, 2021
    так ты либу какую то стороннюю используешь, пользуйся апи там все работает
    The post was merged to previous Jul 4, 2025
    а у тебя видимо что то там сломано
     
    1. View previous comments (5)
    2. Апатия
      Python
      import requests

      url = "https://prod-api.lzt.market/telegram?country[]=US"

      headers = {
      "accept": "application/json",
      "authorization": "Bearer"
      }

      response = requests.get(url, headers=headers)

      print(response.text)
      doonati,
    3. doonati Topic starter
    4. doonati Topic starter
    5. View the next comments (2)
Top
Loading...