async def iter_list_artifacts(
self,
arn: "capo_device_farm.types.amazon_resource_name.AmazonResourceName",
type: "capo_device_farm.types.artifact_category.ArtifactCategory",
*,
config_overrides: Optional[AsyncDeviceFarmClientConfig] = None,
next_token: Optional[
"capo_device_farm.types.pagination_token.PaginationToken"
] = None,
) -> "AsyncIterator[capo_device_farm.types.artifact.Artifact]":
_token = next_token
while True:
_response = await self.list_artifacts(
arn,
type,
config_overrides=config_overrides,
next_token=_token,
)
_page = _resolve_path(_response, ("artifacts",))
for _item in _page or []:
yield _item
_token = _resolve_path(_response, ("next_token",))
if not _token:
break