Forum Discussion

luluberlu's avatar
Occasional Contributor
6 years ago

Add a check of non existence in a API response

i have this kind of API response :    {"response": {"responsesRecherche": {    "1":    {       "consultation":       {          "Id": "16391821108191",          "referenceFonctionnelle": ...
  • luluberlu's avatar
    6 years ago


    I try but it don't work. same error "groovy.lang.MissingPropertyException: No such property: Date de création for class: java.lang.String

    I try this just after : 

    if (Slurp[i].("Date de création")) {
      if (Slurp[i]."Date de création" < testdate) {checkdate = false }
      assert checkdate

    but i got the same error :( 

    i think i should use "contains" method rightly.