wordnik 4.06.07 → 4.06.08

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- wordnik (4.06.06)
4
+ wordnik (4.06.08)
5
5
  activemodel (>= 3.0.3)
6
6
  addressable (>= 2.2.4)
7
7
  htmlentities (>= 4.2.4)
@@ -35,7 +35,7 @@ module Wordnik
35
35
  # Build the default set of resource names from the filenames of the API documentation
36
36
  begin
37
37
  api_docs_path = File.join(File.dirname(__FILE__), "../../api_docs")
38
- @resource_names = `find #{api_docs_path} -name '*.json'`.split("\n").map {|f| f.split("/").last.sub('.json', '') }
38
+ @resource_names = `find #{api_docs_path} -name '*.json'`.split("\n").map {|f| f.split("/").last.sub('.json', '') }.sort
39
39
  true
40
40
  rescue
41
41
  raise "Problem loading the resource files in ./api_docs/"
@@ -1,4 +1,4 @@
1
1
  module Wordnik
2
- VERSION = "4.06.07"
2
+ VERSION = "4.06.08"
3
3
  end
4
4
 
@@ -54,7 +54,7 @@ configure_wordnik
54
54
 
55
55
  def sample_resource_body
56
56
  @sample_resource_body ||= begin
57
- File.open(File.join(File.dirname(__FILE__), "./swagger/word.json"), "r").read
57
+ File.open(File.join(File.dirname(__FILE__), "../api_docs/word.json"), "r").read
58
58
  end
59
59
  end
60
60
 
@@ -0,0 +1,21 @@
1
+ ---
2
+ - !ruby/struct:VCR::HTTPInteraction
3
+ request: !ruby/struct:VCR::Request
4
+ method: :get
5
+ uri: http://localhost:8001/admin/api/word.json/dog/images/flickr
6
+ body:
7
+ headers:
8
+ response: !ruby/struct:VCR::Response
9
+ status: !ruby/struct:VCR::ResponseStatus
10
+ code: 401
11
+ message: Unauthorized
12
+ headers:
13
+ date:
14
+ - Thu, 01 Sep 2011 23:26:54 GMT
15
+ content-type:
16
+ - application/json
17
+ content-length:
18
+ - "44"
19
+ body: "{\"message\": \"unauthorized\", \"type\": \"error\"}"
20
+ http_version: "1.1"
21
+ :@ignored: false
@@ -0,0 +1,25 @@
1
+ ---
2
+ - !ruby/struct:VCR::HTTPInteraction
3
+ request: !ruby/struct:VCR::Request
4
+ method: :get
5
+ uri: http://localhost:8001/admin/api/word.json
6
+ body:
7
+ headers:
8
+ response: !ruby/struct:VCR::Response
9
+ status: !ruby/struct:VCR::ResponseStatus
10
+ code: 200
11
+ message: OK
12
+ headers:
13
+ date:
14
+ - Thu, 01 Sep 2011 23:26:51 GMT
15
+ wordnik-api-version:
16
+ - 4.07.74
17
+ access-control-allow-origin:
18
+ - "*"
19
+ content-length:
20
+ - "26719"
21
+ content-type:
22
+ - application/json
23
+ body: "{\"resourcePath\":\"/word\",\"models\":{\"sizes\":{\"properties\":{\"size\":{\"type\":\"array\",\"items\":{\"$ref\":\"size\"}}},\"id\":\"sizes\"},\"facet\":{\"properties\":{\"facetValue\":{\"type\":\"array\",\"items\":{\"$ref\":\"facetValue\"}},\"name\":{\"type\":\"string\"}},\"id\":\"facet\"},\"sentence\":{\"properties\":{\"id\":{\"type\":\"long\"},\"display\":{\"type\":\"string\"},\"rating\":{\"type\":\"int\"},\"documentMetadataId\":{\"type\":\"long\"},\"scoredWord\":{\"type\":\"array\",\"items\":{\"$ref\":\"scoredWord\"}}},\"id\":\"sentence\"},\"frequency\":{\"properties\":{\"count\":{\"type\":\"long\"},\"year\":{\"type\":\"int\"}},\"id\":\"frequency\"},\"related\":{\"properties\":{\"label1\":{\"type\":\"string\"},\"label2\":{\"type\":\"string\"},\"relationshipType\":{\"type\":\"string\"},\"label3\":{\"type\":\"string\"},\"word\":{\"type\":\"array\",\"items\":{\"type\":\"string\"}},\"gram\":{\"type\":\"string\"},\"label4\":{\"type\":\"string\"}},\"id\":\"related\"},\"exampleSearchResults\":{\"properties\":{\"facet\":{\"type\":\"array\",\"items\":{\"$ref\":\"facet\"}},\"example\":{\"type\":\"array\",\"items\":{\"$ref\":\"example\"}}},\"id\":\"exampleSearchResults\"},\"bigram\":{\"properties\":{\"count\":{\"type\":\"long\"},\"gram2\":{\"type\":\"string\"},\"gram1\":{\"type\":\"string\"},\"wlmi\":{\"type\":\"double\"},\"mi\":{\"type\":\"double\"}},\"id\":\"bigram\"},\"wordObject\":{\"properties\":{\"word\":{\"type\":\"string\"},\"vulgar\":{\"type\":\"string\"}},\"id\":\"wordObject\"},\"ExampleUsage\":{\"properties\":{\"text\":{\"type\":\"string\"}},\"id\":\"ExampleUsage\"},\"note\":{\"properties\":{\"noteType\":{\"type\":\"string\"},\"appliesTo\":{\"type\":\"array\",\"items\":{\"type\":\"string\"}},\"value\":{\"type\":\"string\"},\"pos\":{\"type\":\"int\"}},\"id\":\"note\"},\"citation\":{\"properties\":{\"cite\":{\"type\":\"string\"},\"source\":{\"type\":\"string\"}},\"id\":\"citation\"},\"punctuationFactor\":{\"properties\":{\"periodCount\":{\"type\":\"long\"},\"exclamationPointCount\":{\"type\":\"long\"},\"wordId\":{\"type\":\"long\"},\"questionMarkCount\":{\"type\":\"long\"},\"totalCount\":{\"type\":\"long\"}},\"id\":\"punctuationFactor\"},\"definition\":{\"properties\":{\"extendedText\":{\"type\":\"string\"},\"citation\":{\"type\":\"array\",\"items\":{\"$ref\":\"citation\"}},\"text\":{\"type\":\"string\"},\"sourceDictionary\":{\"type\":\"string\"},\"exampleUsage\":{\"type\":\"array\",\"items\":{\"$ref\":\"ExampleUsage\"}},\"relWord\":{\"type\":\"array\",\"items\":{\"$ref\":\"related\"}},\"score\":{\"type\":\"float\"},\"label\":{\"type\":\"array\",\"items\":{\"$ref\":\"Label\"}},\"seqString\":{\"type\":\"string\"},\"sequence\":{\"type\":\"string\"},\"word\":{\"type\":\"string\"},\"note\":{\"type\":\"array\",\"items\":{\"$ref\":\"note\"}},\"textPron\":{\"type\":\"array\",\"items\":{\"$ref\":\"textPron\"}},\"partOfSpeech\":{\"type\":\"string\"}},\"id\":\"definition\"},\"DefinitionSearchResults\":{\"properties\":{\"result\":{\"type\":\"array\",\"items\":{\"$ref\":\"definition\"}},\"totalResults\":{\"type\":\"int\"}},\"id\":\"DefinitionSearchResults\"},\"photo\":{\"properties\":{\"isfamily\":{\"type\":\"int\"},\"ispublic\":{\"type\":\"int\"},\"linkUri\":{\"type\":\"string\"},\"isfriend\":{\"type\":\"int\"},\"size\":{\"type\":\"size\"},\"id\":{\"type\":\"long\"},\"farm\":{\"type\":\"int\"},\"title\":{\"type\":\"string\"},\"ownerLink\":{\"type\":\"string\"},\"ownername\":{\"type\":\"string\"},\"owner\":{\"type\":\"string\"},\"secret\":{\"type\":\"string\"},\"server\":{\"type\":\"int\"}},\"id\":\"photo\"},\"scoredWord\":{\"properties\":{\"position\":{\"type\":\"int\"},\"id\":{\"type\":\"long\"},\"wordType\":{\"type\":\"string\"},\"score\":{\"type\":\"float\"},\"sentenceId\":{\"type\":\"long\"},\"word\":{\"type\":\"string\"},\"partOfSpeech\":{\"type\":\"string\"}},\"id\":\"scoredWord\"},\"audioType\":{\"properties\":{\"id\":{\"type\":\"int\"},\"name\":{\"type\":\"string\"}},\"id\":\"audioType\"},\"syllable\":{\"properties\":{\"text\":{\"type\":\"string\"},\"seq\":{\"type\":\"int\"},\"type\":{\"type\":\"string\"}},\"id\":\"syllable\"},\"facetValue\":{\"properties\":{\"count\":{\"type\":\"long\"},\"value\":{\"type\":\"string\"}},\"id\":\"facetValue\"},\"contentProvider\":{\"properties\":{\"id\":{\"type\":\"int\"},\"name\":{\"type\":\"string\"}},\"id\":\"contentProvider\"},\"suggestion\":{\"properties\":{\"type\":{\"type\":\"int\"},\"wordstring\":{\"type\":\"string\"}},\"id\":\"suggestion\"},\"Label\":{\"properties\":{\"text\":{\"type\":\"string\"},\"type\":{\"type\":\"string\"}},\"id\":\"Label\"},\"example\":{\"properties\":{\"exampleId\":{\"type\":\"long\"},\"title\":{\"type\":\"string\"},\"text\":{\"type\":\"string\"},\"word\":{\"type\":\"string\"},\"provider\":{\"type\":\"contentProvider\"},\"year\":{\"type\":\"integer\"},\"rating\":{\"type\":\"float\"},\"documentId\":{\"type\":\"long\"},\"url\":{\"type\":\"string\"}},\"id\":\"example\"},\"relationshipMap\":{\"properties\":{\"sourceWordstring\":{\"type\":\"string\"},\"suggestion\":{\"type\":\"array\",\"items\":{\"$ref\":\"suggestion\"}}},\"id\":\"relationshipMap\"},\"frequencySummary\":{\"properties\":{\"unknownYearCount\":{\"type\":\"int\"},\"totalCount\":{\"type\":\"long\"},\"word\":{\"type\":\"string\"},\"frequency\":{\"type\":\"array\",\"items\":{\"$ref\":\"frequency\"}}},\"id\":\"frequencySummary\"},\"audioFile\":{\"properties\":{\"id\":{\"type\":\"long\",\"required\":true},\"duration\":{\"type\":\"double\"},\"createdBy\":{\"type\":\"string\"},\"createdAt\":{\"type\":\"Date\"},\"description\":{\"type\":\"string\"},\"voteWeightedAverage\":{\"type\":\"float\"},\"voteAverage\":{\"type\":\"float\"},\"word\":{\"type\":\"string\"},\"commentCount\":{\"type\":\"int\"},\"voteCount\":{\"type\":\"integer\"},\"audioType\":{\"type\":\"string\"},\"fileUrl\":{\"type\":\"string\"}},\"id\":\"audioFile\"},\"partOfSpeech\":{\"properties\":{\"roots\":{\"type\":\"array\",\"items\":{\"$ref\":\"root\"}}},\"id\":\"partOfSpeech\"},\"textPron\":{\"properties\":{\"raw\":{\"type\":\"string\"},\"id\":{\"type\":\"long\"},\"seq\":{\"type\":\"int\"},\"rawType\":{\"type\":\"string\"}},\"id\":\"textPron\"}},\"apis\":[{\"path\":\"/word.{format}/{word}/examples\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to return examples for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"includeDuplicates\",\"description\":\"Show duplicate examples from different sources\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"contentProvider\",\"description\":\"Return results from a specific ContentProvider\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"internalDataStore\",\"description\":\"Specify the internal storage engine.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"skip\",\"description\":\"Results to skip\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns examples for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.model.ExampleSearchResults\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getExamples\",\"responseClass\":\"exampleSearchResults\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/wordForms\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to fetch forms for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return a correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns other forms of a word\",\"responseTypeInternal\":\"com.wordnik.corpus.entity.RelationshipMap\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400},{\"reason\":\"No results.\",\"code\":404}],\"nickname\":\"getWordForms\",\"responseClass\":\"relationshipMap\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"String value of WordObject to return\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"includeSuggestions\",\"description\":\"Return suggestions (for correct spelling, case variants, etc.)\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"shouldCreate\",\"description\":\"Create word if not existing\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Given a word as a string, returns the WordObject that represents it\",\"responseTypeInternal\":\"com.wordnik.corpus.entity.Word\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getWord\",\"responseClass\":\"wordObject\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/definitions\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to return definitions for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"partOfSpeech\",\"description\":\"CSV list of part-of-speech types\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"noun\",\"adjective\",\"verb\",\"adverb\",\"interjection\",\"pronoun\",\"preposition\",\"abbreviation\",\"affix\",\"article\",\"auxiliary-verb\",\"conjunction\",\"definite-article\",\"family-name\",\"given-name\",\"idiom\",\"imperative\",\"noun-plural\",\"noun-posessive\",\"past-participle\",\"phrasal-prefix\",\"proper-noun\",\"proper-noun-plural\",\"proper-noun-posessive\",\"suffix\",\"verb-intransitive\",\"verb-transitive\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"includeRelated\",\"description\":\"Return related words with definitions\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"true\",\"false\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"sourceDictionaries\",\"description\":\"Gets from dictionaries in the supplied order of precedence\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\" century\",\" wiktionary\",\" webster\",\" wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"includeTags\",\"description\":\"Return a closed set of XML tags in response\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Return definitions for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.dictionary.entity.Definition\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400},{\"reason\":\"No definitions found.\",\"code\":404}],\"nickname\":\"getDefinitions\",\"responseClass\":\"List[definition]\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/topExample\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to fetch examples for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"contentProvider\",\"description\":\"Return results from a specific ContentProvider\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"internalDataStore\",\"description\":\"Specify the internal storage engine.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns a top example for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.model.Example\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getTopExample\",\"responseClass\":\"example\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/punctuationFactor\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to return\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"caseSensitive\",\"description\":\"Input is case sensitive\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"Use the canonical form of the word.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Fetches other forms of a word\",\"responseTypeInternal\":\"com.wordnik.corpus.entity.BangFactor\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400},{\"reason\":\"No results.\",\"code\":404}],\"nickname\":\"getPunctuationFactor\",\"responseClass\":\"punctuationFactor\",\"notes\":\"Deprecated\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/contextualLookup\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to return definitions for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"sentence\",\"description\":\"The sentence in which the word occurs\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"offset\",\"defaultValue\":\"-1\",\"description\":\"The start character offset of the word in the given sentence\",\"required\":false,\"dataType\":\"int\",\"allowableValues\":[\"0 to 4096\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"expandTerms\",\"description\":\"Expand context terms using related words\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"true\",\"false\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"includeSourceDictionaries\",\"description\":\"Only include these comma-delimited source dictionaries\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\" century\",\" wiktionary\",\" webster\",\" wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"excludeSourceDictionaries\",\"description\":\"Exclude these comma-delimited source dictionaries\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\" century\",\" wiktionary\",\" webster\",\" wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"skip\",\"defaultValue\":\"0\",\"description\":\"Results to skip\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"0 to 1000\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"defaultValue\":\"10\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"1 to 1000\"],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns definitions for a word based on the sentence in which it is found\",\"responseTypeInternal\":\"com.wordnik.index.definition.DefinitionSearchResults\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"contextualLookup\",\"responseClass\":\"DefinitionSearchResults\",\"notes\":\"Use the offset parameter when the word occurs more than once in the sentence\",\"httpMethod\":\"GET\"},{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to return definitions for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"description\":\"The sentence in which the word occurs\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"body\"},{\"name\":\"offset\",\"defaultValue\":\"-1\",\"description\":\"The start character offset of the word in the given sentence\",\"required\":false,\"dataType\":\"int\",\"allowableValues\":[\"0 to 4096\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"expandTerms\",\"description\":\"Expand context terms using related words\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"true\",\"false\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"includeSourceDictionaries\",\"description\":\"Only include these comma-delimited source dictionaries\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\" century\",\" wiktionary\",\" webster\",\" wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"excludeSourceDictionaries\",\"description\":\"Exclude these comma-delimited source dictionaries\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\" century\",\" wiktionary\",\" webster\",\" wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"skip\",\"defaultValue\":\"0\",\"description\":\"Results to skip\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"0 to 1000\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"defaultValue\":\"10\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"1 to 1000\"],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns definitions for a word based on the sentence in which it is found\",\"responseTypeInternal\":\"com.wordnik.index.definition.DefinitionSearchResults\",\"errorResponses\":[{\"reason\":\"Invalid term supplied.\",\"code\":400}],\"nickname\":\"contextualLookupPost\",\"responseClass\":\"DefinitionSearchResults\",\"notes\":\"Use the offset parameter when the word occurs more than once in the sentence\",\"httpMethod\":\"POST\"}]},{\"path\":\"/word.{format}/{word}/related\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word for which to return related words\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"partOfSpeech\",\"description\":\"CSV list of part-of-speech types\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"noun\",\"adjective\",\"verb\",\"adverb\",\"interjection\",\"pronoun\",\"preposition\",\"abbreviation\",\"affix\",\"article\",\"auxiliary-verb\",\"conjunction\",\"definite-article\",\"family-name\",\"given-name\",\"idiom\",\"imperative\",\"noun-plural\",\"noun-posessive\",\"past-participle\",\"phrasal-prefix\",\"proper-noun\",\"proper-noun-plural\",\"proper-noun-posessive\",\"suffix\",\"verb-intransitive\",\"verb-transitive\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"sourceDictionary\",\"description\":\"Get data from a single dictionary\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\" century\",\" wiktionary\",\" webster\",\" wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"type\",\"description\":\"Relationship type\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"synonym\",\"antonym\",\"variant\",\"equivalent\",\"cross-reference\",\"related-word\",\"rhyme\",\"form\",\"etymologically-related-term\",\"hypernym\",\"hyponym\",\"inflected-form\",\"primary\",\"same-context\",\"verb-form\",\"verb-stem\",\"unknown\"],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Return related words (thesaurus data) for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.dictionary.entity.Related\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400},{\"reason\":\"No definitions found.\",\"code\":404}],\"nickname\":\"getRelatedWords\",\"responseClass\":\"List[related]\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/pronunciations\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to get pronunciations for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return a correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"sourceDictionary\",\"description\":\"Get from a single dictionary.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\"century\",\"cmu\",\"macmillan\",\"wiktionary\",\"webster\",\"wordnet\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"typeFormat\",\"description\":\"Text pronunciation type\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"ahd\",\"arpabet\",\"gcide-diacritical\",\"IPA\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns text pronunciations for a given word\",\"responseTypeInternal\":\"com.wordnik.corpus.dictionary.entity.TextPron\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getTextPronunciations\",\"responseClass\":\"List[textPron]\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/images/flickr\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to get flickr images for.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"size\",\"description\":\"Image size\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"thumb\",\"small\",\"med\",\"lg\",\"orig\"],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns Flickr images for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.model.FlickrImage\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getFlickrImages\",\"responseClass\":\"List[photo]\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/hyphenation\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to get syllables for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return a correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"sourceDictionary\",\"description\":\"Get from a single dictionary. Valid options: ahd, century, wiktionary, webster, and wordnet.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns syllable information for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.dictionary.entity.Syllable\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getHyphenation\",\"responseClass\":\"List[syllable]\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/frequency\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to return\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"caseSensitive\",\"description\":\"Input is case sensitive\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"startYear\",\"description\":\"Starting Year\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"endYear\",\"description\":\"Ending Year\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"includeErrorBars\",\"description\":\"Get error bar data\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Returns word usage over time\",\"responseTypeInternal\":\"com.wordnik.corpus.entity.FrequencySummary\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400},{\"reason\":\"No results.\",\"code\":404}],\"nickname\":\"getWordFrequency\",\"responseClass\":\"frequencySummary\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/phrases\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to fetch phrases for\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"wlmi\",\"description\":\"Minimum WLMI for the phrase\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"useCanonical\",\"description\":\"If true will try to return the correct word root ('cats' -> 'cat'). If false returns exactly what was requested.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[\"false\",\"true\"],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Fetches bi-gram phrases for a word\",\"responseTypeInternal\":\"com.wordnik.corpus.ngram.entity.Bigram\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getPhrases\",\"responseClass\":\"List[bigram]\",\"httpMethod\":\"GET\"}]},{\"path\":\"/word.{format}/{word}/audio\",\"description\":\"\",\"operations\":[{\"parameters\":[{\"name\":\"word\",\"description\":\"Word to get audio for.\",\"required\":true,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"path\"},{\"name\":\"useCanonical\",\"description\":\"Use the canonical form of the word.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"v3Format\",\"description\":\"Use the V3 api.\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"paramAccess\":\"internal\",\"allowMultiple\":false,\"paramType\":\"query\"},{\"name\":\"limit\",\"description\":\"Maximum number of results to return\",\"required\":false,\"dataType\":\"string\",\"allowableValues\":[],\"allowMultiple\":false,\"paramType\":\"query\"}],\"summary\":\"Fetches audio metadata for a word.\",\"responseTypeInternal\":\"com.wordnik.community.entity.AudioFileMetadata\",\"errorResponses\":[{\"reason\":\"Invalid word supplied.\",\"code\":400}],\"nickname\":\"getAudio\",\"responseClass\":\"List[audioFile]\",\"notes\":\"The metadata includes a time-expiring fileUrl which allows reading the audio file directly from the API. Currently only audio pronunciations from the American Heritage Dictionary in mp3 format are supported.\",\"httpMethod\":\"GET\"}]}],\"basePath\":\"url\",\"swaggerVersion\":\"1.0\"}"
24
+ http_version: "1.1"
25
+ :@ignored: false
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: wordnik
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 4.06.07
5
+ version: 4.06.08
6
6
  platform: ruby
7
7
  authors:
8
8
  - Zeke Sikelianos
@@ -11,7 +11,7 @@ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
13
 
14
- date: 2011-08-31 00:00:00 Z
14
+ date: 2011-09-01 00:00:00 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: typhoeus
@@ -205,8 +205,10 @@ files:
205
205
  - spec/spec_helper.rb
206
206
  - spec/vcr/crazier_json_request.yml
207
207
  - spec/vcr/default_response.yml
208
+ - spec/vcr/get_dog_images.yml
208
209
  - spec/vcr/get_word_dynamo.yml
209
210
  - spec/vcr/unauthorized_response.yml
211
+ - spec/vcr/word_resource.yml
210
212
  - spec/vcr/wordnik_authenticate.yml
211
213
  - spec/vcr/wordnik_authenticate_fail.yml
212
214
  - spec/vcr/xml_response_request.yml
@@ -251,8 +253,10 @@ test_files:
251
253
  - spec/spec_helper.rb
252
254
  - spec/vcr/crazier_json_request.yml
253
255
  - spec/vcr/default_response.yml
256
+ - spec/vcr/get_dog_images.yml
254
257
  - spec/vcr/get_word_dynamo.yml
255
258
  - spec/vcr/unauthorized_response.yml
259
+ - spec/vcr/word_resource.yml
256
260
  - spec/vcr/wordnik_authenticate.yml
257
261
  - spec/vcr/wordnik_authenticate_fail.yml
258
262
  - spec/vcr/xml_response_request.yml