diff --git a/categories.txt b/categories.txt index 3397dd4..ba066a4 100644 --- a/categories.txt +++ b/categories.txt @@ -1,40 +1,40 @@ -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_cenchroides -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_amurensis -https://commons.wikimedia.org/wiki/Category:Quality_images_of_captive_Falco_berigora -https://commons.wikimedia.org/wiki/Category:Quality_images_of_captive_Falco_biarmicus -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_cherrug -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_columbarius -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_naumanni -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_rusticolus -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_sparverius -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_tinnunculus -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Falco_vespertinus -https://commons.wikimedia.org/wiki/Category:Quality_images_of_Caracara_plancus +Category:Quality_images_of_Falco_cenchroides +Category:Quality_images_of_Falco_amurensis +Category:Quality_images_of_captive_Falco_berigora +Category:Quality_images_of_captive_Falco_biarmicus +Category:Quality_images_of_Falco_cherrug +Category:Quality_images_of_Falco_columbarius +Category:Quality_images_of_Falco_naumanni +Category:Quality_images_of_Falco_rusticolus +Category:Quality_images_of_Falco_sparverius +Category:Quality_images_of_Falco_tinnunculus +Category:Quality_images_of_Falco_vespertinus +Category:Quality_images_of_Caracara_plancus Category:Quality_images_of_Accipiter_badius Category:Quality_images_of_Accipiter_cooperii Category:Quality_images_of_Accipiter_minullus Category:Quality_images_of_Accipiter_nisus -Category:Quality images of Aquila audax -Category:Quality images of Aquila chrysaetos -Category:Quality images of captive Aquila heliaca -Category:Quality images of captive Aquila nipalensis -Category:Quality images of Aquila spilogaster -Category:Quality images of Buteo augur -Category:Quality images of Buteo buteo -Category:Quality images of Buteo galapagoensis -Category:Quality images of Buteo jamaicensis -Category:Quality images of Buteo lineatus -Category:Quality images of Buteo regalis -Category:Quality images of Buteogallus -Category:Quality images of Circaetus gallicus -Category:Quality images of Circaetus pectoralis -Category:Quality images of Circus aeruginosus -Category:Quality images of Circus cyaneus -Category:Quality images of Circus hudsonius -Category:Quality images of Haliaeetus albicilla -Category:Quality images of Haliaeetus leucocephalus -Category:Quality images of Haliaeetus leucogaster -Category:Quality images of captive Haliaeetus pelagicus -Category:Quality images of Haliaeetus vocifer -Category:Quality images of Haliastur indus -Category:Quality images of Haliastur sphenurus \ No newline at end of file +Category:Quality_images_of_Aquila_audax +Category:Quality_images_of_Aquila_chrysaetos +Category:Quality_images_of_captive_Aquila_heliaca +Category:Quality_images_of_captive_Aquila_nipalensis +Category:Quality_images_of_Aquila_spilogaster +Category:Quality_images_of_Buteo_augur +Category:Quality_images_of_Buteo_buteo +Category:Quality_images_of_Buteo_galapagoensis +Category:Quality_images_of_Buteo_jamaicensis +Category:Quality_images_of_Buteo_lineatus +Category:Quality_images_of_Buteo_regalis +Category:Quality_images_of_Buteogallus +Category:Quality_images_of_Circaetus_gallicus +Category:Quality_images_of_Circaetus_pectoralis +Category:Quality_images_of_Circus_aeruginosus +Category:Quality_images_of_Circus_cyaneus +Category:Quality_images_of_Circus_hudsonius +Category:Quality_images_of_Haliaeetus_albicilla +Category:Quality_images_of_Haliaeetus_leucocephalus +Category:Quality_images_of_Haliaeetus_leucogaster +Category:Quality_images_of_captive_Haliaeetus_pelagicus +Category:Quality_images_of_Haliaeetus_vocifer +Category:Quality_images_of_Haliastur_indus +Category:Quality_images_of_Haliastur_sphenurus \ No newline at end of file diff --git a/server.rb b/server.rb index f739d4d..0a515ed 100644 --- a/server.rb +++ b/server.rb @@ -21,4 +21,9 @@ get '/api/random' do content_type :json image = get_random_image(get_images_by_category(categories)) image.to_json +end + +get '/api/categories' do + content_type :json + categories.to_json end \ No newline at end of file