code: def register_blueprint(self, blueprint: Blueprint, url_prefix: Optional[str]=None) -> None:
          
          first_registration = False
          if blueprint.name in self.blueprints and self.blueprints[blueprint.name] is not blueprint:
              raise RuntimeError(
                  f"Blueprint name '{blueprint.name}' "
                  f"is already registered by {self.blueprints[blueprint.name]}. "
                  "Blueprints must have unique names",
              )
          else:
              self.blueprints[blueprint.name] = blueprint
              first_registration = True
          blueprint.register(self, first_registration, url_prefix=url_prefix)
docs: Register a blueprint on the app.
  
          This results in the blueprint's routes, error handlers
          etc... being added to the app.
  
          Arguments:
              blueprint: The blueprint to register.
              url_prefix: Optional prefix to apply to all paths.