Unable to get barset using alpaca live credentials

import alpaca_trade_api as alpaca_api
from alpaca_trade_api.common import URL
import pandas as pd

ALPACA_API_URL = “https://api.alpaca.markets
ALPACA_API_SECRET_KEY = KEY
ALPACA_API_KEY = SECRET

alpaca_api = alpaca_api.REST(
ALPACA_API_KEY,
ALPACA_API_SECRET_KEY,
base_url=URL(ALPACA_API_URL),
api_version=“v2”,
)

NY = ‘America/New_York’
end = pd.Timestamp.now(tz=NY)
start = end - pd.Timedelta(‘50 days’)
print(alpaca_api.get_barset(‘AMD’, ‘day’, start=start, end=end, limit=1000).df)

Response :
Traceback (most recent call last):
File “/home/alpaca_test.py”, line 49, in
print(alpaca_api.get_barset(‘AMD’, ‘day’, start=start, end=end, limit=1000).df)
File “/home/lib/python3.9/site-packages/alpaca_trade_api/rest.py”, line 473, in get_barset
resp = self.data_get(’/bars/{}’.format(timeframe), params)
File “/home//home/lib/python3.9/site-packages/alpaca_trade_api/rest.py”, line 178, in data_get
return self._request(
File “/home/lib/python3.9/site-packages/alpaca_trade_api/rest.py”, line 125, in _request
return self._one_request(method, url, opts, retry)
File “/home/lib/python3.9/site-packages/alpaca_trade_api/rest.py”, line 146, in _one_request
resp.raise_for_status()
File “/home/lib/python3.9/site-packages/requests/models.py”, line 943, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://data.alpaca.markets/v1/bars/day?symbols=AMD&limit=1000&start=2021-01-28+13%3A55%3A47.590517-05%3A00&end=2021-03-19+14%3A55%3A47.590517-04%3A00

Barset is being removed… you have to use the updated methods/endpoints