def make_auto_deployable(self, stage, swagger=None):
if not swagger:<EOL><INDENT>return<EOL><DEDENT>generator = logical_id_generator.LogicalIdGenerator(self.logical_id, str(swagger))<EOL>self.logical_id = generator.gen()<EOL>hash = generator.get_hash(length=<NUM_LIT>)  <EOL>self.Description = "<STR_LIT>".format(hash)<EOL>stage.update_deployment_ref(self.logical_id)<EOL>
Sets up the resource such that it will triggers a re-deployment when Swagger changes

:param swagger: Dictionary containing the Swagger definition of the API