def parts(self,
              name=None,
              pk=None,
              model=None,
              category=Category.INSTANCE,
              bucket=None,
              parent=None,
              activity=None,
              limit=None,
              batch=100,
              **kwargs):
        if limit and limit < batch:
            batch = limit
        request_params = {
            'id': pk,
            'name': name,
            'model': model.id if model else None,
            'category': category,
            'bucket': bucket,
            'parent': parent,
            'activity_id': activity,
            'limit': batch
        }
        if kwargs:
            request_params.update(**kwargs)
        response = self._request('GET', self._build_url('parts'), params=request_params)
        if response.status_code != requests.codes.ok:
            raise NotFoundError("Could not retrieve parts")
        data = response.json()
        part_results = data['results']
        if batch and data.get('next'):
            while data['next']:
                if limit and len(part_results) >= limit:
                    break
                response = self._request('GET', data['next'])
                data = response.json()
                part_results.extend(data['results'])
        return PartSet((Part(p, client=self) for p in part_results))