code: def set_scope(self, http_method, scope):
          
  
          for con in self.conditions:
              if http_method in con['httpMethods']:
                  if isinstance(scope, list):
                      con['scopes'] = scope
                  elif isinstance(scope, str) or isinstance(scope, unicode):
                      con['scopes'].append(scope)
                  return
          # If not present, then create a new condition
          if isinstance(scope, list):
              self.conditions.append({'httpMethods': [http_method],
                                      'scopes': scope})
          elif isinstance(scope, str) or isinstance(scope, unicode):
              self.conditions.append({'httpMethods': [http_method],
                                      'scopes': [scope]})
docs: Set a scope condition for the resource for a http_method
  
          Parameters:
              * **http_method (str):** HTTP method like GET, POST, PUT, DELETE
              * **scope (str, list):** the scope of access control as str if single, or as a list of strings if multiple scopes are to be set