Skip to main content

RequestQueueClient

Request queue resource client implementation based on the Apify platform storage.

Index

Methods

__init__

  • __init__(*, apify_request_queue_client): None
  • Parameters

    • optionalkeyword-onlyapify_request_queue_client: RequestQueueClientAsync

    Returns None

add_request

  • async add_request(*, request, forefront): ProcessedRequest
  • Parameters

    • optionalkeyword-onlyrequest: Request
    • optionalkeyword-onlyforefront: bool = False

    Returns ProcessedRequest

batch_add_requests

  • async batch_add_requests(*, requests, forefront): BatchRequestsOperationResponse
  • Parameters

    • optionalkeyword-onlyrequests: Sequence[Request]
    • optionalkeyword-onlyforefront: bool = False

    Returns BatchRequestsOperationResponse

batch_delete_requests

  • async batch_delete_requests(*, requests): BatchRequestsOperationResponse
  • Parameters

    • optionalkeyword-onlyrequests: list[Request]

    Returns BatchRequestsOperationResponse

delete

  • async delete(): None
  • Returns None

delete_request

  • async delete_request(*, request_id): None
  • Parameters

    • optionalkeyword-onlyrequest_id: str

    Returns None

delete_request_lock

  • async delete_request_lock(*, request_id, forefront): None
  • Parameters

    • optionalkeyword-onlyrequest_id: str
    • optionalkeyword-onlyforefront: bool = False

    Returns None

get

  • async get(): RequestQueueMetadata | None
  • Returns RequestQueueMetadata | None

get_request

  • async get_request(*, request_id): Request | None
  • Parameters

    • optionalkeyword-onlyrequest_id: str

    Returns Request | None

list_and_lock_head

  • async list_and_lock_head(*, lock_secs, limit): RequestQueueHeadWithLocks
  • Parameters

    • optionalkeyword-onlylock_secs: int
    • optionalkeyword-onlylimit: int | None = None

    Returns RequestQueueHeadWithLocks

list_head

  • async list_head(*, limit): RequestQueueHead
  • Parameters

    • optionalkeyword-onlylimit: int | None = None

    Returns RequestQueueHead

prolong_request_lock

  • async prolong_request_lock(*, request_id, forefront, lock_secs): ProlongRequestLockResponse
  • Parameters

    • optionalkeyword-onlyrequest_id: str
    • optionalkeyword-onlyforefront: bool = False
    • optionalkeyword-onlylock_secs: int

    Returns ProlongRequestLockResponse

update

  • async update(*, name): RequestQueueMetadata
  • Parameters

    • optionalkeyword-onlyname: str | None = None

    Returns RequestQueueMetadata

update_request

  • async update_request(*, request, forefront): ProcessedRequest
  • Parameters

    • optionalkeyword-onlyrequest: Request
    • optionalkeyword-onlyforefront: bool = False

    Returns ProcessedRequest