code: def api_arrival(
          self,
          airport: Union[str, Airport],
          begin: Optional[timelike] = None,
          end: Optional[timelike] = None,
      ) -> pd.DataFrame:
          
  
          if isinstance(airport, str):
              from .. import airports
  
              airport_code = airports[airport].icao
          else:
              airport_code = airport.icao
  
          if begin is None:
              begin = round_time(datetime.now(timezone.utc), by=timedelta(days=1))
          begin = to_datetime(begin)
          if end is None:
              end = begin + timedelta(days=1)
          else:
              end = to_datetime(end)
  
          begin = int(begin.timestamp())
          end = int(end.timestamp())
  
          c = requests.get(
              f"https://opensky-network.org/api/flights/arrival"
              f"?begin={begin}&airport={airport_code}&end={end}"
          )
  
          if c.status_code != 200:
              raise ValueError(c.content.decode())
  
          return (
              pd.DataFrame.from_records(c.json())[
                  [
                      "firstSeen",
                      "lastSeen",
                      "icao24",
                      "callsign",
                      "estDepartureAirport",
                      "estArrivalAirport",
                  ]
              ]
              .assign(
                  firstSeen=lambda df: pd.to_datetime(
                      df.firstSeen * 1e9
                  ).dt.tz_localize("utc"),
                  lastSeen=lambda df: pd.to_datetime(
                      df.lastSeen * 1e9
                  ).dt.tz_localize("utc"),
              )
              .sort_values("lastSeen")
          )
docs: Returns a flight table associated to an airport.
  
          By default, returns the current table. Otherwise, you may enter a
          specific date (as a string, as an epoch or as a datetime)
  
          Official documentation
          ----------------------
  
          Retrieve flights for a certain airport which arrived within a given time
          interval [begin, end]. If no flights are found for the given period,
          HTTP stats 404 - Not found is returned with an empty response body.