def instance(self, counter=None, pipeline_counter=None):
pipeline_counter = pipeline_counter or self.pipeline_counter<EOL>pipeline_instance = None<EOL>if not pipeline_counter:<EOL><INDENT>pipeline_instance = self.server.pipeline(self.pipeline_name).instance()<EOL>self.pipeline_counter = int(pipeline_instance['<STR_LIT>'])<EOL><DEDENT>if not counter:<EOL><INDENT>if pipeline_instance is None:<EOL><INDENT>pipeline_instance = (<EOL>self.server<EOL>.pipeline(self.pipeline_name)<EOL>.instance(pipeline_counter)<EOL>)<EOL><DEDENT>for stages in pipeline_instance['<STR_LIT>']:<EOL><INDENT>if stages['<STR_LIT:name>'] == self.stage_name:<EOL><INDENT>return self.instance(<EOL>counter=int(stages['<STR_LIT>']),<EOL>pipeline_counter=pipeline_counter<EOL>)<EOL><DEDENT><DEDENT><DEDENT>return self._get('<STR_LIT>'<EOL>.format(pipeline_counter=pipeline_counter, counter=counter))<EOL>
Returns all the information regarding a specific stage run

        See the `Go stage instance documentation`__ for examples.

        .. __: http://api.go.cd/current/#get-stage-instance

        Args:
          counter (int): The stage instance to fetch.
            If falsey returns the latest stage instance from :meth:`history`.
          pipeline_counter (int): The pipeline instance for which to fetch
            the stage. If falsey returns the latest pipeline instance.

        Returns:
          Response: :class:`gocd.api.response.Response` object