docs: def _validate_body_parameters(self, body, action_spec):
          """Check the body parameter for the action specification.
  
          Args:
              body: body parameter to check.
              action_spec: specification of the action.
  
          Returns:
              True if the body is valid.
              A string containing an error msg in case the body did not validate,
              otherwise the string is empty
          """
          processed_params = []
          for param_name, param_spec in action_spec['parameters'].items():
              if param_spec['in'] == 'body':
                  processed_params.append(param_name)
  
                  # Check type
                  if 'type' in param_spec.keys() and not self.check_type(body, param_spec['type']):
                      msg = "Check type did not validate for {0} and {1}".format(param_spec['type'], body)
                      return False, msg
                  # Check schema
                  elif 'schema' in param_spec.keys():
                      if 'type' in param_spec['schema'].keys() and param_spec['schema']['type'] == 'array':
                          # It is an array get value from definition
                          definition_name = self.get_definition_name_from_ref(param_spec['schema']['items']['$ref'])
                          if len(body) > 0 and not self.validate_definition(definition_name, body[0]):
                              msg = "The body did not validate against its definition"
                              return False, msg
                      elif ('type' in param_spec['schema'].keys() and not
                            self.check_type(body, param_spec['schema']['type'])):
                          # Type but not array
                          msg = "Check type did not validate for {0} and {1}".format(param_spec['schema']['type'], body)
                          return False, msg
                      else:
                          definition_name = self.get_definition_name_from_ref(param_spec['schema']['$ref'])
                          if not self.validate_definition(definition_name, body):
                              msg = "The body did not validate against its definition"
                              return False, msg
          # Check required
          if not all(param in processed_params for param, spec in action_spec['parameters'].items()
                     if spec['in'] == 'body' and 'required' in spec and spec['required']):
              msg = "Not all required parameters were present"
              return False, msg
  
          return True, ""