code: def test_groupby_resample_on_api_with_getitem():
      # GH 17813
      df = DataFrame(
          {
              "id": list("aabbb"),
              "date": date_range("1-1-2016", periods=5),
              "data": 1,
          }
      )
      exp = (
          df.set_index("date")
          .groupby("id")
          .resample("2D")["data"]
          .sum()
      )
      result = df.groupby("id").resample("2D", on="date")["data"].sum()
      tm.assert_series_equal(result, exp)
  
imports: from textwrap import dedent
  import numpy
  import pytest
  from pandas.compat import is_platform_windows
  import pandas
  from pandas import DataFrame, Index, Series, TimedeltaIndex, Timestamp
  import pandas._testing
  from pandas.core.indexes.datetimes import date_range
label_desc: Use image node_id 6 for calling a global function with example usage: test_groupby_resample_on_api_with_getitem() without return types