





import shutil

import requests
def  __UpperCamelCase    (						snake_case							,			snake_case = False							,			snake_case = "."      )    ->		Optional[Any]:


   '''simple docstring'''







   __A    =  'https://api.nasa.gov/planetary/apod'
   return requests.get(lowerCAmelCase__							,			params={'''api_key''': api_key}      ).json()
def  __UpperCamelCase    (						snake_case							,			snake_case = "."      )    ->		str:


   '''simple docstring'''







   __A    =  get_apod_data(lowerCAmelCase__      )
   __A    =  apod_data['url']
   __A    =  img_url.split('''/'''      )[-1]
   __A    =  requests.get(lowerCAmelCase__							,			stream=lowerCAmelCase__      )

   with open(F"{path}/{img_name}"							,			'''wb+'''      ) as img_file:
      shutil.copyfileobj(response.raw							,			lowerCAmelCase__      )
   del response
   return apod_data
def  __UpperCamelCase    (						snake_case      )    ->		Any:


   '''simple docstring'''







   __A    =  'https://images-api.nasa.gov/search'
   return requests.get(lowerCAmelCase__							,			params={'''q''': query}      ).json()


if __name__ == "__main__":
    print(save_apod("""YOUR API KEY"""))
    _UpperCamelCase       :				Optional[int]           =			get_archive_data("""apollo 2011""")["""collection"""]["""items"""]
    print(apollo_aaaa_items[0]["""data"""][0]["""description"""])









def        _lowerCamelCase(      lowerCAmelCase__					:		float     ,     lowerCAmelCase__					:		float     ,     lowerCAmelCase__					:		float   ):





				'''simple docstring'''







				if mass < 0:
								raise ValueError('The mass of the body cannot be negative'   )
				if radius <= 0:
								raise ValueError('The radius is always a positive non zero integer'   )
				return (mass * (velocity) ** 2) / radius


if __name__ == "__main__":
				import doctest

				doctest.testmod(verbose=True)