Helper function to generate a single row of a price table.

  Args:
    header: A str containing the header text of this row.
    description: A str description of this row in the price table.
    final_url: A str containing the final URL after all cross domain redirects.
    price_in_micros: An int indicating the price of the given currency in
      micros.
    currency_code: A str indicating the currency code being used.
    price_unit: A str enum indicating the price unit for this row.
    final_mobile_url: A str containing the final mobile URL after all cross
      domain redirects.

  Returns:
    A dictionary containing the contents of the generated price table row.

def CreatePriceTableRow(header, description, final_url, price_in_micros,
                        currency_code, price_unit, final_mobile_url=None):
  """Helper function to generate a single row of a price table.

  Args:
    header: A str containing the header text of this row.
    description: A str description of this row in the price table.
    final_url: A str containing the final URL after all cross domain redirects.
    price_in_micros: An int indicating the price of the given currency in
      micros.
    currency_code: A str indicating the currency code being used.
    price_unit: A str enum indicating the price unit for this row.
    final_mobile_url: A str containing the final mobile URL after all cross
      domain redirects.

  Returns:
    A dictionary containing the contents of the generated price table row.
  """
  table_row = {
      'header': header,
      'description': description,
      'finalUrls': {'urls': [final_url]},
      'price': {
          'money': {
              'microAmount': price_in_micros,
          },
          'currencyCode': currency_code
      },
      'priceUnit': price_unit,
      'xsi_type': 'PriceTableRow'
  }

  if final_mobile_url:
    table_row['finalMobileUrls'] = {
        'urls': [final_mobile_url]
    }

  return table_row