Skip to main content

REST API routes

  • - POST /api/search/form (searching for word forms)
    • - input json:
      • - string: written form to search for
      • - type: 'orthography'
      • - extra-data: ['related-pronunciation-ipa']
    • - output json:
      • - list of forms which match the input string, with each element represented with:
        • - id: id of the form
        • - type: the type of the form (for your calls, this would be 'orthography', matching the input 'type' parameter)
        • - lexeme_id: id of the form's lexeme (word)
        • - lemma: the lexeme's basic form
        • - msd: the form's Slovene JOS msd (e.g., "Somem")
        • - text: the text of the form (for your calls, this will match the input 'string' parameter)
        • - related-forms: list of lists of forms related to this form, of the types requested (in your case this would just contain the pronunciation ipa matches)
      • - for example:
        • - GET /api/search/form with json {'string':'klopi', 'type':'orthography', 'extra-data':'related-pronunciation-ipa'}
          • -> [{'id':300, 'type':'orthography', 'lexeme_id':123, 'lemma':'klop', 'msd':'Sommi', 'text':'klopi', 'related-forms':[[{'id':100, 'type':'pronunciation', 'text':ˈklɔːpi', 'script':'ipa'}]]}, {'id':301, 'type':'orthography', 'lexeme_id':124, 'lemma':'klop', 'msd':'Sozer', 'text':'klopi', 'related-forms':[[{'id':101, 'type':'pronunciation', 'text':'klɔ\ˈpiː', 'script':'ipa'}]]}, {'id':302, 'type':'orthography', 'lexeme_id':124, 'lemma':'klop', 'msd':'Sozed', 'text':'klopi', 'related-forms':[[{'id':102, 'type':'pronunciation', 'text':'\ˈkloːpi', 'script':'ipa'}]]}, ...]