From 60fbe68f78b2c87c5d827a3ca3f3a5619ae59614 Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 11:22:52 -0400 Subject: [PATCH 01/10] Add punctuation check for Description --- build/validate_format.rb | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index 820ef7d2..783d73fe 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -1,5 +1,6 @@ #!/usr/bin/env ruby auth_keys = ['apiKey', 'OAuth', 'X-Mashape-Key', 'No'] +punctuation = ['.', '?', '!'] https_keys = ['Yes', 'No'] args = ARGV filename = args[0] @@ -12,25 +13,35 @@ File.foreach(filename).with_index do |line, line_num| next end values = line.split("|") - # Check Description to make sure first character is capitalized + ################# DESCRIPTION ################ + # First character should be capitalized desc_val = values[2].lstrip.chop if !/[[:upper:]]/.match(desc_val[0]) puts "(#{line_num}) Invalid Description (first char not uppercase): #{desc_val}" fail_flag = true end - # Check Auth values to conform to valid options only + # value should not be punctuated + last_char = desc_val[desc_val.length-1] + if punctuation.include?(last_char) + puts "(#{line_num}) Invalid Description (description should not end with \"#{last_char}\")" + fail_flag = true + end + #################### AUTH #################### + # Values should conform to valid options only auth_val = values[3].lstrip.chop.tr('``', '') if !auth_keys.include?(auth_val) puts "(#{line_num}) Invalid Auth (not a valid option): #{auth_val}" fail_flag = true end - # Check HTTPS Support values to be either "Yes" or "No" + #################### HTTPS ################### + # Values should be either "Yes" or "No" https_val = values[4].lstrip.chop if !https_keys.include?(https_val) puts "(#{line_num}) Invalid HTTPS: (must use \"Yes\" or \"No\"): #{https_val}" fail_flag = true end - # Check Link to ensure url is wrapped in "[Go!]" view + #################### LINK #################### + # Url should be wrapped in "[Go!]" view link_val = values[5].lstrip.chop if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') puts "(#{line_num}) Invalid Link: (format should be \"[Go!]()\"): #{link_val}" From e2b71b22c4571f3659f16b2d88d3200bf462b8c6 Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 11:25:35 -0400 Subject: [PATCH 02/10] add errors to array and remove fail flag --- build/validate_format.rb | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index 783d73fe..9260c3aa 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -1,11 +1,17 @@ #!/usr/bin/env ruby + auth_keys = ['apiKey', 'OAuth', 'X-Mashape-Key', 'No'] punctuation = ['.', '?', '!'] https_keys = ['Yes', 'No'] args = ARGV filename = args[0] -fail_flag = false -File.foreach(filename).with_index do |line, line_num| +$errors = [] + +def add_error(line_num, message) + $errors.push("(L%03d) #{message}" % line_num) +end + +File.foreach(filename).with_index do | line, line_num | line_num += 1 if line.start_with?('|') # Skip table schema lines @@ -17,39 +23,37 @@ File.foreach(filename).with_index do |line, line_num| # First character should be capitalized desc_val = values[2].lstrip.chop if !/[[:upper:]]/.match(desc_val[0]) - puts "(#{line_num}) Invalid Description (first char not uppercase): #{desc_val}" - fail_flag = true + add_error(line_num, "Invalid Description (first char not uppercase): #{desc_val}") end # value should not be punctuated last_char = desc_val[desc_val.length-1] if punctuation.include?(last_char) - puts "(#{line_num}) Invalid Description (description should not end with \"#{last_char}\")" - fail_flag = true + add_error(line_num, "Invalid Description (description should not end with \"#{last_char}\")") end #################### AUTH #################### # Values should conform to valid options only auth_val = values[3].lstrip.chop.tr('``', '') if !auth_keys.include?(auth_val) - puts "(#{line_num}) Invalid Auth (not a valid option): #{auth_val}" - fail_flag = true + add_error(line_num, "Invalid Auth (not a valid option): #{auth_val}") end #################### HTTPS ################### # Values should be either "Yes" or "No" https_val = values[4].lstrip.chop if !https_keys.include?(https_val) - puts "(#{line_num}) Invalid HTTPS: (must use \"Yes\" or \"No\"): #{https_val}" - fail_flag = true + add_error(line_num, "(#{line_num}) Invalid HTTPS: (must use \"Yes\" or \"No\"): #{https_val}") end #################### LINK #################### # Url should be wrapped in "[Go!]" view link_val = values[5].lstrip.chop if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') - puts "(#{line_num}) Invalid Link: (format should be \"[Go!]()\"): #{link_val}" - fail_flag = true + add_error(line_num, "(#{line_num}) Invalid Link: (format should be \"[Go!]()\"): #{link_val}") end end end -if fail_flag +if $errors.length > 0 + $errors.each do | e | + puts e + end exit(1) else exit(0) From fbd07b8f4bf9848a45b189d226d8ead6fdc4c4ff Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 11:40:21 -0400 Subject: [PATCH 03/10] Add padding check for each line value --- build/validate_format.rb | 36 +++++++++++++++++++++++++++++++----- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index 9260c3aa..00eabc31 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -18,35 +18,61 @@ File.foreach(filename).with_index do | line, line_num | if line.eql? "|---|---|---|---|---|\n" next end + values = line.split("|") + + values.each.with_index do |val, val_index| + msg = "" + case val_index + when 1..5 + if val[0] != " " || val[val.length-1] != " " + case val_index + when 1 + msg = "spacing on Title is invalid" + when 2 + msg = "spacing on Description is invalid" + when 3 + msg = "spacing on Auth is invalid" + when 4 + msg = "spacing on HTTPS is invalid" + when 5 + msg = "spacing on Link is invalid" + end + end + end + if msg != "" + add_error(line_num, "#{msg} (pad before and after string)") + end + end + ################# DESCRIPTION ################ # First character should be capitalized desc_val = values[2].lstrip.chop if !/[[:upper:]]/.match(desc_val[0]) - add_error(line_num, "Invalid Description (first char not uppercase): #{desc_val}") + add_error(line_num, "invalid Description (first char not uppercase): #{desc_val}") end # value should not be punctuated last_char = desc_val[desc_val.length-1] if punctuation.include?(last_char) - add_error(line_num, "Invalid Description (description should not end with \"#{last_char}\")") + add_error(line_num, "invalid Description (description should not end with \"#{last_char}\")") end #################### AUTH #################### # Values should conform to valid options only auth_val = values[3].lstrip.chop.tr('``', '') if !auth_keys.include?(auth_val) - add_error(line_num, "Invalid Auth (not a valid option): #{auth_val}") + add_error(line_num, "invalid Auth (not a valid option): #{auth_val}") end #################### HTTPS ################### # Values should be either "Yes" or "No" https_val = values[4].lstrip.chop if !https_keys.include?(https_val) - add_error(line_num, "(#{line_num}) Invalid HTTPS: (must use \"Yes\" or \"No\"): #{https_val}") + add_error(line_num, "invalid HTTPS (must use \"Yes\" or \"No\"): #{https_val}") end #################### LINK #################### # Url should be wrapped in "[Go!]" view link_val = values[5].lstrip.chop if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') - add_error(line_num, "(#{line_num}) Invalid Link: (format should be \"[Go!]()\"): #{link_val}") + add_error(line_num, "invalid Link (format should be \"[Go!]()\"): #{link_val}") end end end From 105c745ac93e8ef808050a09c8dc69a0e705de10 Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 11:49:32 -0400 Subject: [PATCH 04/10] move segment check logic to method --- build/validate_format.rb | 43 ++++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 22 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index 00eabc31..e9edd7e2 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -7,8 +7,21 @@ args = ARGV filename = args[0] $errors = [] -def add_error(line_num, message) - $errors.push("(L%03d) #{message}" % line_num) +def add_error(line_num, val_index, message) + case val_index + when 1 + segment = "Title" + when 2 + segment = "Description" + when 3 + segment = "Auth" + when 4 + segment = "HTTPS" + when 5 + segment = "Link" + end + + $errors.push("(L%03d) (#{segment}) #{message}" % line_num) end File.foreach(filename).with_index do | line, line_num | @@ -26,53 +39,39 @@ File.foreach(filename).with_index do | line, line_num | case val_index when 1..5 if val[0] != " " || val[val.length-1] != " " - case val_index - when 1 - msg = "spacing on Title is invalid" - when 2 - msg = "spacing on Description is invalid" - when 3 - msg = "spacing on Auth is invalid" - when 4 - msg = "spacing on HTTPS is invalid" - when 5 - msg = "spacing on Link is invalid" - end + add_error(line_num, val_index, "spacing is invalid (pad before and after string)") end end - if msg != "" - add_error(line_num, "#{msg} (pad before and after string)") - end end ################# DESCRIPTION ################ # First character should be capitalized desc_val = values[2].lstrip.chop if !/[[:upper:]]/.match(desc_val[0]) - add_error(line_num, "invalid Description (first char not uppercase): #{desc_val}") + add_error(line_num, 2, "first char not uppercase") end # value should not be punctuated last_char = desc_val[desc_val.length-1] if punctuation.include?(last_char) - add_error(line_num, "invalid Description (description should not end with \"#{last_char}\")") + add_error(line_num, 2, "description should not end with \"#{last_char}\"") end #################### AUTH #################### # Values should conform to valid options only auth_val = values[3].lstrip.chop.tr('``', '') if !auth_keys.include?(auth_val) - add_error(line_num, "invalid Auth (not a valid option): #{auth_val}") + add_error(line_num, 3, "not a valid option: #{auth_val}") end #################### HTTPS ################### # Values should be either "Yes" or "No" https_val = values[4].lstrip.chop if !https_keys.include?(https_val) - add_error(line_num, "invalid HTTPS (must use \"Yes\" or \"No\"): #{https_val}") + add_error(line_num, 4, "must use \"Yes\" or \"No\": #{https_val}") end #################### LINK #################### # Url should be wrapped in "[Go!]" view link_val = values[5].lstrip.chop if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') - add_error(line_num, "invalid Link (format should be \"[Go!]()\"): #{link_val}") + add_error(line_num, 5, "format should be \"[Go!]()\": #{link_val}") end end end From ffddb7bbae8c840c54d0a4510905588ab36c7252 Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 11:54:43 -0400 Subject: [PATCH 05/10] use constants to represent line segment index --- build/validate_format.rb | 39 ++++++++++++++++++++++----------------- 1 file changed, 22 insertions(+), 17 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index e9edd7e2..20b5833c 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -3,21 +3,26 @@ auth_keys = ['apiKey', 'OAuth', 'X-Mashape-Key', 'No'] punctuation = ['.', '?', '!'] https_keys = ['Yes', 'No'] -args = ARGV -filename = args[0] + +INDEX_TITLE = 1 +INDEX_DESCRIPTION = 2 +INDEX_AUTH = 3 +INDEX_HTTPS = 4 +INDEX_LINK = 5 +filename = ARGV[0] $errors = [] def add_error(line_num, val_index, message) case val_index - when 1 + when INDEX_TITLE segment = "Title" - when 2 + when INDEX_DESCRIPTION segment = "Description" - when 3 + when INDEX_AUTH segment = "Auth" - when 4 + when INDEX_HTTPS segment = "HTTPS" - when 5 + when INDEX_LINK segment = "Link" end @@ -37,7 +42,7 @@ File.foreach(filename).with_index do | line, line_num | values.each.with_index do |val, val_index| msg = "" case val_index - when 1..5 + when INDEX_TITLE..INDEX_LINK if val[0] != " " || val[val.length-1] != " " add_error(line_num, val_index, "spacing is invalid (pad before and after string)") end @@ -46,32 +51,32 @@ File.foreach(filename).with_index do | line, line_num | ################# DESCRIPTION ################ # First character should be capitalized - desc_val = values[2].lstrip.chop + desc_val = values[INDEX_DESCRIPTION].lstrip.chop if !/[[:upper:]]/.match(desc_val[0]) - add_error(line_num, 2, "first char not uppercase") + add_error(line_num, INDEX_DESCRIPTION, "first char not uppercase") end # value should not be punctuated last_char = desc_val[desc_val.length-1] if punctuation.include?(last_char) - add_error(line_num, 2, "description should not end with \"#{last_char}\"") + add_error(line_num, INDEX_DESCRIPTION, "description should not end with \"#{last_char}\"") end #################### AUTH #################### # Values should conform to valid options only - auth_val = values[3].lstrip.chop.tr('``', '') + auth_val = values[INDEX_AUTH].lstrip.chop.tr('``', '') if !auth_keys.include?(auth_val) - add_error(line_num, 3, "not a valid option: #{auth_val}") + add_error(line_num, INDEX_AUTH, "not a valid option: #{auth_val}") end #################### HTTPS ################### # Values should be either "Yes" or "No" - https_val = values[4].lstrip.chop + https_val = values[INDEX_HTTPS].lstrip.chop if !https_keys.include?(https_val) - add_error(line_num, 4, "must use \"Yes\" or \"No\": #{https_val}") + add_error(line_num, INDEX_HTTPS, "must use \"Yes\" or \"No\": #{https_val}") end #################### LINK #################### # Url should be wrapped in "[Go!]" view - link_val = values[5].lstrip.chop + link_val = values[INDEX_LINK].lstrip.chop if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') - add_error(line_num, 5, "format should be \"[Go!]()\": #{link_val}") + add_error(line_num, INDEX_LINK, "format should be \"[Go!]()\": #{link_val}") end end end From 10bc3049c15d0360d8a644f3e147da400dc312ca Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 12:10:33 -0400 Subject: [PATCH 06/10] exit code is num of errors and formatting --- build/validate_format.rb | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index 20b5833c..baf9244f 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -26,7 +26,7 @@ def add_error(line_num, val_index, message) segment = "Link" end - $errors.push("(L%03d) (#{segment}) #{message}" % line_num) + $errors.push("(L%03d) %-14.14s #{message}" % [line_num, segment]) end File.foreach(filename).with_index do | line, line_num | @@ -44,7 +44,7 @@ File.foreach(filename).with_index do | line, line_num | case val_index when INDEX_TITLE..INDEX_LINK if val[0] != " " || val[val.length-1] != " " - add_error(line_num, val_index, "spacing is invalid (pad before and after string)") + add_error(line_num, val_index, "pad before and after string with spaces") end end end @@ -80,11 +80,7 @@ File.foreach(filename).with_index do | line, line_num | end end end -if $errors.length > 0 - $errors.each do | e | - puts e - end - exit(1) -else - exit(0) +$errors.each do | e | + puts e end +exit($errors.length) From 3a79096bdbeef14f94aca240a39cae907b2e3fc6 Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 12:32:39 -0400 Subject: [PATCH 07/10] use regex to check number of padding spaces --- build/test.rb | 3 +++ build/validate_format.rb | 7 ++++--- 2 files changed, 7 insertions(+), 3 deletions(-) create mode 100644 build/test.rb diff --git a/build/test.rb b/build/test.rb new file mode 100644 index 00000000..416349f0 --- /dev/null +++ b/build/test.rb @@ -0,0 +1,3 @@ +s = " lol " +puts s[/\A +/].size +puts s[/ +\z/].size \ No newline at end of file diff --git a/build/validate_format.rb b/build/validate_format.rb index baf9244f..a85a6edc 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -39,16 +39,17 @@ File.foreach(filename).with_index do | line, line_num | values = line.split("|") + ################### GLOBAL ################### values.each.with_index do |val, val_index| msg = "" case val_index when INDEX_TITLE..INDEX_LINK - if val[0] != " " || val[val.length-1] != " " - add_error(line_num, val_index, "pad before and after string with spaces") + # every line segment should start and end with exactly 1 space + if val[/\A */].size != 1 || val[/ *\z/].size != 1 + add_error(line_num, val_index, "string should start and end with exactly 1 space") end end end - ################# DESCRIPTION ################ # First character should be capitalized desc_val = values[INDEX_DESCRIPTION].lstrip.chop From 8c74f6fe68380c3dec1f807d125691b2a64d2891 Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 14:16:41 -0400 Subject: [PATCH 08/10] clean up after myself --- build/test.rb | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 build/test.rb diff --git a/build/test.rb b/build/test.rb deleted file mode 100644 index 416349f0..00000000 --- a/build/test.rb +++ /dev/null @@ -1,3 +0,0 @@ -s = " lol " -puts s[/\A +/].size -puts s[/ +\z/].size \ No newline at end of file From 01161074fa382bbf55405278418eb212081e9fdd Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Fri, 28 Jul 2017 14:35:32 -0400 Subject: [PATCH 09/10] pop main logic out one level by reversing condition --- build/validate_format.rb | 87 ++++++++++++++++++++-------------------- 1 file changed, 43 insertions(+), 44 deletions(-) diff --git a/build/validate_format.rb b/build/validate_format.rb index a85a6edc..a8f10f3c 100755 --- a/build/validate_format.rb +++ b/build/validate_format.rb @@ -31,54 +31,53 @@ end File.foreach(filename).with_index do | line, line_num | line_num += 1 - if line.start_with?('|') - # Skip table schema lines - if line.eql? "|---|---|---|---|---|\n" - next - end + + # Skip non-markdown table lines and table schema lines + if !line.start_with?('|') || line.eql?("|---|---|---|---|---|\n") + next + end - values = line.split("|") + values = line.split("|") - ################### GLOBAL ################### - values.each.with_index do |val, val_index| - msg = "" - case val_index - when INDEX_TITLE..INDEX_LINK - # every line segment should start and end with exactly 1 space - if val[/\A */].size != 1 || val[/ *\z/].size != 1 - add_error(line_num, val_index, "string should start and end with exactly 1 space") - end + ################### GLOBAL ################### + values.each.with_index do |val, val_index| + msg = "" + case val_index + when INDEX_TITLE..INDEX_LINK + # every line segment should start and end with exactly 1 space + if val[/\A */].size != 1 || val[/ *\z/].size != 1 + add_error(line_num, val_index, "string should start and end with exactly 1 space") end end - ################# DESCRIPTION ################ - # First character should be capitalized - desc_val = values[INDEX_DESCRIPTION].lstrip.chop - if !/[[:upper:]]/.match(desc_val[0]) - add_error(line_num, INDEX_DESCRIPTION, "first char not uppercase") - end - # value should not be punctuated - last_char = desc_val[desc_val.length-1] - if punctuation.include?(last_char) - add_error(line_num, INDEX_DESCRIPTION, "description should not end with \"#{last_char}\"") - end - #################### AUTH #################### - # Values should conform to valid options only - auth_val = values[INDEX_AUTH].lstrip.chop.tr('``', '') - if !auth_keys.include?(auth_val) - add_error(line_num, INDEX_AUTH, "not a valid option: #{auth_val}") - end - #################### HTTPS ################### - # Values should be either "Yes" or "No" - https_val = values[INDEX_HTTPS].lstrip.chop - if !https_keys.include?(https_val) - add_error(line_num, INDEX_HTTPS, "must use \"Yes\" or \"No\": #{https_val}") - end - #################### LINK #################### - # Url should be wrapped in "[Go!]" view - link_val = values[INDEX_LINK].lstrip.chop - if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') - add_error(line_num, INDEX_LINK, "format should be \"[Go!]()\": #{link_val}") - end + end + ################# DESCRIPTION ################ + # First character should be capitalized + desc_val = values[INDEX_DESCRIPTION].lstrip.chop + if !/[[:upper:]]/.match(desc_val[0]) + add_error(line_num, INDEX_DESCRIPTION, "first char not uppercase") + end + # value should not be punctuated + last_char = desc_val[desc_val.length-1] + if punctuation.include?(last_char) + add_error(line_num, INDEX_DESCRIPTION, "description should not end with \"#{last_char}\"") + end + #################### AUTH #################### + # Values should conform to valid options only + auth_val = values[INDEX_AUTH].lstrip.chop.tr('``', '') + if !auth_keys.include?(auth_val) + add_error(line_num, INDEX_AUTH, "not a valid option: #{auth_val}") + end + #################### HTTPS ################### + # Values should be either "Yes" or "No" + https_val = values[INDEX_HTTPS].lstrip.chop + if !https_keys.include?(https_val) + add_error(line_num, INDEX_HTTPS, "must use \"Yes\" or \"No\": #{https_val}") + end + #################### LINK #################### + # Url should be wrapped in "[Go!]" view + link_val = values[INDEX_LINK].lstrip.chop + if !link_val.start_with?("[Go!](") || !link_val.end_with?(')') + add_error(line_num, INDEX_LINK, "format should be \"[Go!]()\": #{link_val}") end end $errors.each do | e | From cb6908dcffa7b68fa66bf4d864ff3af7b22b3b7f Mon Sep 17 00:00:00 2001 From: Dave Machado Date: Sat, 29 Jul 2017 13:14:43 -0400 Subject: [PATCH 10/10] Update README to conform to formatting --- README.md | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index 06eea493..c33e55ff 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ API | Description | Auth | HTTPS | Link | | Harvard Art Museums | Art | `apiKey` | No | [Go!](https://github.com/harvardartmuseums/api-docs) | | Icons8 | Icons | `OAuth` | Yes | [Go!](http://docs.icons8.apiary.io/#reference/0/meta) | | Noun Project | Icons | `OAuth` | No | [Go!](http://api.thenounproject.com/index.html) | -| Rijksmuseum| Art | `apiKey` | Yes | [Go!](https://www.rijksmuseum.nl/en/api) | +| Rijksmuseum | Art | `apiKey` | Yes | [Go!](https://www.rijksmuseum.nl/en/api) | ### Books API | Description | Auth | HTTPS | Link | @@ -169,9 +169,9 @@ API | Description | Auth | HTTPS | Link | | Gitter | Chat for GitHub | `OAuth` | Yes | [Go!](https://github.com/gitterHQ/docs) | | HackerRank | Compile source code and run against a set of provided test cases | `apiKey` | Yes | [Go!](https://www.hackerrank.com/api/docs) | | Hipster Ipsum | Generates Hipster Ipsum text | No | No | [Go!](http://hipsterjesus.com/) | -| IPify | A simple IP Address API | No | Yes | [Go!](https://www.ipify.org/) | +| IPify | A simple IP Address API | No | Yes | [Go!](https://www.ipify.org/) | | JSON 2 JSONP | Convert JSON to JSONP (on-the-fly) for easy cross-domain data requests using client-side JavaScript | No | Yes | [Go!](https://json2jsonp.com/) | -| JSONbin.io | Free JSON storage service. Ideal for small scale Web apps, Websites and Mobile apps. | No | Yes | [Go!](https://jsonbin.io) | +| JSONbin.io | Free JSON storage service. Ideal for small scale Web apps, Websites and Mobile apps | No | Yes | [Go!](https://jsonbin.io) | | JSONPlaceholder | Fake data for testing and prototyping | No | No | [Go!](http://jsonplaceholder.typicode.com/) | | Judge0 API | Compile and run source code | No | Yes | [Go!](https://api.judge0.com/) | | Kairos | Face Recognition and Emotion Analysis | `apiKey` | Yes | [Go!](https://www.kairos.com/features) | @@ -197,7 +197,7 @@ API | Description | Auth | HTTPS |Link | | File.io | File Sharing | No | Yes | [Go!](https://www.file.io) | | pdflayer API | HTML/URL to PDF | No | Yes | [Go!](https://pdflayer.com) | | Pocket | Bookmarking service | `OAuth` | Yes | [Go!](https://getpocket.com/developer/) | -| PrexView | Data from XML or JSON to PDF, HTML or Image | `apiKey` | Yes | [Go!](https://prexview.com) | +| PrexView | Data from XML or JSON to PDF, HTML or Image | `apiKey` | Yes | [Go!](https://prexview.com) | | Todoist | Todo Lists | `OAuth` | Yes | [Go!](https://developer.todoist.com) | | Wunderlist | Todo Lists | `OAuth` | Yes | [Go!](https://developer.wunderlist.com/documentation) | @@ -239,8 +239,8 @@ API | Description | Auth | HTTPS | Link | | Whitepages Pro | Global identity verification with phone, address, email, and IP | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/identity-check-api/) | | Whitepages Pro | Phone reputation to detect spammy phones | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/phone-reputation-api/) | | Whitepages Pro | Get an owner’s name, address, demographics based on the phone number | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/reverse-phone-api/) | -| Whitepages Pro| Phone number validation, line_type, carrier append | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/phone-intelligence-api/) | -| Whitepages Pro| Get normalized physical address, residents, address type, and validity. | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/reverse-address-api/) | +| Whitepages Pro | Phone number validation, line_type, carrier append | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/phone-intelligence-api/) | +| Whitepages Pro | Get normalized physical address, residents, address type, and validity | `apiKey` | Yes | [Go!](https://pro.whitepages.com/developer/documentation/reverse-address-api/) | ### Games & Comics API | Description | Auth | HTTPS | Link | @@ -270,20 +270,20 @@ API | Description | Auth | HTTPS | Link | ### Geocoding API | Description | Auth | HTTPS | Link | |---|---|---|---|---| -| adresse.data.gouv.fr | Address database of France. geocoding and reverse. | No | Yes | [Go!](https://adresse.data.gouv.fr) | +| adresse.data.gouv.fr | Address database of France, geocoding, and reverse | No | Yes | [Go!](https://adresse.data.gouv.fr) | | Bing Maps | Create/customize digital maps based on Bing Maps data | `apiKey` | Yes | [Go!](https://www.microsoft.com/maps/) | | Geocode.xyz | Provides worldwide forward/reverse geocoding, batch geocoding and geoparsing | No | Yes | [Go!](https://geocode.xyz/) | | GeoNames | Place names and other geographical data | No | No | [Go!](http://www.geonames.org/export/web-services.html) | | GéoApi | French geographical data | No | Yes | [Go!](https://api.gouv.fr/api/geoapi.html) | | Google Maps | Create/customize digital maps based on Google Maps data | `apiKey` | Yes | [Go!](https://developers.google.com/maps/) | | IP 2 Country | Map an IP to a country | No | Yes | [Go!](https://ip2country.info) | -| IP Address Details| Find geolocation with ip address | No | Yes | [Go!](https://ipinfo.io/) | -| IP Location| Find IP address location information | No | Yes | [Go!](https://ipapi.co/) | +| IP Address Details | Find geolocation with ip address | No | Yes | [Go!](https://ipinfo.io/) | +| IP Location | Find IP address location information | No | Yes | [Go!](https://ipapi.co/) | | IP Vigilante | Free IP Geolocation API | No | Yes | [Go!](https://www.ipvigilante.com/) | | Mapbox | Create/customize beautiful digital maps | `apiKey` | Yes | [Go!](https://www.mapbox.com/developers/) | | Mapzen Search | Open Source & Open Data Global Geocoding Service | `apiKey` | Yes | [Go!](https://mapzen.com/products/search/) | | Mexico | Mexico RESTful zip codes API | No | Yes | [Go!](https://github.com/IcaliaLabs/sepomex) | -| One Map 2.0, Singapore| Singapore Land Authority REST API services for Singapore addresses | `apiKey` | Yes | [Go!](https://docs.onemap.sg/) | +| One Map 2.0, Singapore | Singapore Land Authority REST API services for Singapore addresses | `apiKey` | Yes | [Go!](https://docs.onemap.sg/) | | OnWater | Determine if a lat/lon is on water or land | No | Yes | [Go!](https://onwater.io/) | | OpenCage | Forward and reverse geocoding using open data | No | Yes | [Go!](https://geocoder.opencagedata.com) | | OpenStreetMap | Navigation, geolocation and geographical data | `OAuth` | No | [Go!](http://wiki.openstreetmap.org/wiki/API) | @@ -336,7 +336,7 @@ API | Description | Auth | HTTPS | Link | | MusicBrainz | Music | No | Yes | [Go!](https://musicbrainz.org/doc/Development/XML_Web_Service/Version_2) | | Musikki | Music | No | Yes | [Go!](https://music-api.musikki.com/reference) | | Musixmatch | Music | `apiKey` | Yes | [Go!](https://developer.musixmatch.com/) | -| Songsterr | Provides guitar, bass and drums tabs and chords | No | Yes | [Go!](https://www.songsterr.com/a/wa/api/) | +| Songsterr | Provides guitar, bass and drums tabs and chords | No | Yes | [Go!](https://www.songsterr.com/a/wa/api/) | | Soundcloud | Music | No | Yes | [Go!](https://developers.soundcloud.com/) | | Spotify | Music | `OAuth` | Yes | [Go!](https://developer.spotify.com/web-api/) | | Vagalume | Crowdsourced lyrics and music knowledge | `apiKey` | Yes | [Go!](https://api.vagalume.com.br/docs/) | @@ -351,7 +351,7 @@ API | Description | Auth | HTTPS | Link | ### Open Source projects API | Description | Auth | HTTPS | Link | |---|---|---|---|---| -| Countly | Countly web analytics | No | No | [Go!](http://resources.count.ly/docs) | +| Countly | Countly web analytics | No | No | [Go!](http://resources.count.ly/docs) | | Drupal.org | Drupal.org | No | Yes | [Go!](https://www.drupal.org/drupalorg/docs/api) | | Libraries.io | Open source software libraries | `apiKey` | Yes | [Go!](https://libraries.io/api) | @@ -361,7 +361,7 @@ API | Description | Auth | HTTPS | Link | | chucknorris.io | JSON API for hand curated Chuck Norris jokes | No | Yes | [Go!](https://api.chucknorris.io) | | Forismatic | Inspirational Quotes | No | No | [Go!](http://forismatic.com/en/api/) | | icanhazdadjoke | The largest selection of dad jokes on the internet | No | Yes | [Go!](https://icanhazdadjoke.com/api) | -| Medium | Community of readers and writers offering unique perspectives on ideas. | `OAuth` | Yes | [Go!](https://github.com/Medium/medium-api-docs) | +| Medium | Community of readers and writers offering unique perspectives on ideas | `OAuth` | Yes | [Go!](https://github.com/Medium/medium-api-docs) | | Quotes on Design | Inspirational Quotes | No | Yes | [Go!](https://quotesondesign.com/api-v4-0/) | | Traitify | Assess, collect, and analyze Personality | No | Yes | [Go!](https://app.traitify.com/developer) | | tronalddump.io | Api & web archive for the things Donald Trump has said | No | Yes | [Go!](https://www.tronalddump.io) | @@ -369,7 +369,7 @@ API | Description | Auth | HTTPS | Link | ### Photography API | Description | Auth | HTTPS | Link | |---|---|---|---|---| -| 500px | Photography Community | `OAuth` | Yes | [Go!](https://github.com/500px/api-documentation) | +| 500px | Photography Community | `OAuth` | Yes | [Go!](https://github.com/500px/api-documentation) | | Flickr | Flickr Services | `OAuth` | Yes | [Go!](https://www.flickr.com/services/api/) | | Gfycat | Jiffier GIFs | `OAuth` | Yes | [Go!](https://developers.gfycat.com/api/) | | Giphy | Get all your gifs | No | Yes | [Go!](https://github.com/Giphy/GiphyAPI) | @@ -388,7 +388,7 @@ API | Description | Auth | HTTPS | Link | | Minor Planet Center | Asterank.com Information | No | No | [Go!](http://www.asterank.com/mpc) | | NASA | NASA data, including imagery | No | Yes | [Go!](https://api.nasa.gov) | | Open Notify | ISS astronauts, current location, etc | No | No | [Go!](http://open-notify.org/Open-Notify-API/) | -| Sunrise and Sunset | Sunset and sunrise times for a given latitude and longitude. | No | Yes | [Go!](https://sunrise-sunset.org/api) | +| Sunrise and Sunset | Sunset and sunrise times for a given latitude and longitude | No | Yes | [Go!](https://sunrise-sunset.org/api) | | USGS Earthquake Hazards Program | Earthquakes data real-time | No | Yes | [Go!](https://earthquake.usgs.gov/fdsnws/event/1/) | | USGS Water Services | Water quality and level info for rivers and lakes | No | Yes | [Go!](https://waterservices.usgs.gov/) | | World Bank | World Data | No | No | [Go!](https://datahelpdesk.worldbank.org/knowledgebase/topics/125589) | @@ -431,7 +431,7 @@ API | Description | Auth | HTTPS | Link | ### Sports & Fitness API | Description | Auth | HTTPS | Link | |---|---|---|---|---| -| Cartola FC | The Cartola FC API serves to check the partial points of your team. | No | Yes | [Go!](https://github.com/wgenial/cartrolandofc) | +| Cartola FC | The Cartola FC API serves to check the partial points of your team | No | Yes | [Go!](https://github.com/wgenial/cartrolandofc) | | City Bikes | City Bikes around the world | No | No | [Go!](http://api.citybik.es/v2/) | | Ergast F1 | F1 data from the beginning of the world championships in 1950 | No | No | [Go!](http://ergast.com/mrd/) | | Fitbit | Fitbit Information | `OAuth` | Yes | [Go!](https://dev.fitbit.com/) | @@ -448,7 +448,7 @@ API | Description | Auth | HTTPS | Link | API | Description | Auth | HTTPS | Link | |---|---|---|---|---| | Postmon | An API to query Brazilian ZIP codes and orders easily, quickly and free | No | No | [Go!](http://postmon.com.br) | -| Sweden | Provides information about parcels in transport | `apiKey` | No | [Go!](https://developer.postnord.com/docs2) | +| Sweden | Provides information about parcels in transport | `apiKey` | No | [Go!](https://developer.postnord.com/docs2) | ### Transportation API | Description | Auth | HTTPS | Link | @@ -456,14 +456,14 @@ API | Description | Auth | HTTPS | Link | | Amadeus Travel Innovation Sandbox | Travel Search - Limited usage | `apiKey` | Yes | [Go!](https://sandbox.amadeus.com/) | | Bay Area Rapid Transit | Stations and predicted arrivals for BART | `apiKey` | No | [Go!](http://api.bart.gov) | | Community Transit | Transitland API | No | Yes | [Go!](https://github.com/transitland/transitland-datastore/blob/master/README.md#api-endpoints) | -| Goibibo | API for travel search | `apiKey` | Yes | [Go!](https://developer.goibibo.com/docs) | +| Goibibo | API for travel search | `apiKey` | Yes | [Go!](https://developer.goibibo.com/docs) | | Indian Railways | Indian Railways Information | `apiKey` | No | [Go!](http://api.erail.in/) | | Navitia | The open API for building cool stuff with transport data | `apiKey` | Yes | [Go!](https://api.navitia.io/) | | The Nomad List | A list of the best places to live/work remotely | No | Yes | [Go!](https://nomadlist.com/faq) | | Schiphol Airport | Schiphol | `apiKey` | Yes | [Go!](https://developer.schiphol.nl/) | | TransitLand | Transit Aggregation | No | Yes | [Go!](https://transit.land/documentation/datastore/api-endpoints.html) | | Transport for Atlanta, US | Marta | No | No | [Go!](http://www.itsmarta.com/app-developer-resources.aspx) | -| Transport for Auckland, New Zealand | Auckland Transport API | No | Yes | [Go!](https://api.at.govt.nz/) | +| Transport for Auckland, New Zealand | Auckland Transport | No | Yes | [Go!](https://api.at.govt.nz/) | | Transport for Belgium | Belgian transport API | No | Yes | [Go!](https://hello.irail.be/api/) | | Transport for Berlin, Germany | Third-party VBB API | No | Yes | [Go!](https://github.com/derhuerst/vbb-rest/blob/master/docs/index.md) | | Transport for Boston, US | MBTA API | No | No | [Go!](http://realtime.mbta.com/Portal/Home/Documents) | @@ -497,12 +497,12 @@ API | Description | Auth | HTTPS | Link | | Transport for Victoria, AU | PTV API | `apiKey` | Yes | [Go!](https://www.ptv.vic.gov.au/about-ptv/ptv-data-and-reports/digital-products/ptv-timetable-api/) | | Transport for Washington, US | Washington Metro transport API | `OAuth` | Yes | [Go!](https://developer.wmata.com/) | | Uber | Request Uber rides, reach riders, transport things, and reward drivers | `OAuth` | Yes | [Go!](https://developer.uber.com/) | -| WhereIsMyTransport | Platform for public transport data in emerging cities | `OAuth` | Yes | [Go!](https://developer.whereismytransport.com/) | +| WhereIsMyTransport | Platform for public transport data in emerging cities | `OAuth` | Yes | [Go!](https://developer.whereismytransport.com/) | ### University API | Description | Auth | HTTPS | Link | |---|---|---|---|---| -| Universities List | University names, countries and domains| No | Yes | [Go!](https://github.com/Hipo/university-domains-list) | +| Universities List | University names, countries and domains | No | Yes | [Go!](https://github.com/Hipo/university-domains-list) | ### Vehicle API | Description | Auth | HTTPS | Link | @@ -522,7 +522,7 @@ API | Description | Auth | HTTPS | Link | | TMDb | Community-based movie data | `apiKey` | Yes | [Go!](https://www.themoviedb.org/documentation/api) | | TVMaze | TV Show Data | No | No | [Go!](http://www.tvmaze.com/api) | | Vimeo | Vimeo Developer API | `OAuth` | Yes | [Go!](https://developer.vimeo.com/) | -| YouTube | Add YouTube functionality to your sites and apps. | `OAuth` | Yes | [Go!](https://developers.google.com/youtube/) | +| YouTube | Add YouTube functionality to your sites and apps | `OAuth` | Yes | [Go!](https://developers.google.com/youtube/) | ### Weather API | Description | Auth | HTTPS | Link |