Skip to main content

KeyValueStoreClient

Sub-client for manipulating a single key-value store.

Index

Methods

delete

  • delete(): None

delete_record

  • delete_record(key): None

get

  • get(): dict | None

get_record

  • get_record(key, *, as_bytes, as_file): dict | None
  • Retrieve the given record from the key-value store.

    https://docs.apify.com/api/v2#/reference/key-value-stores/record/get-record


    Parameters

    • key: str

      Key of the record to retrieve

    • keyword-onlyas_bytes: bool = False

      Deprecated, use get_record_as_bytes() instead. Whether to retrieve the record as raw bytes, default False

    • keyword-onlyas_file: bool = False

      Deprecated, use stream_record() instead. Whether to retrieve the record as a file-like object, default False

    Returns dict | None

    The requested record, or None, if the record does not exist

get_record_as_bytes

  • get_record_as_bytes(key): dict | None

list_keys

  • list_keys(*, limit, exclusive_start_key): dict

set_record

  • set_record(key, value, content_type): None

stream_record

  • stream_record(key): Iterator[dict | None]

update

  • update(*, name): dict